35 Higher order functions are simply functions that can either accept functions or closures as arguments or return a function/closure. Higher Order Functions are very useful and powerful and help us to write more elegantly and maintainable code. Those functions are Map, Filter, Reduce, Sort, CompactMap etc. let result = [listOne.compactMap({ $0}),listTwo.compactMap({ $0})].flatMap({ $0}).reduce(0) { $0 + $1 } First compact map removes nil element from the array. Then by using a flat map, we combine these two arrays. And finally, reduce function will help to get the sum of array elements. This, along with other senior iOS developer interview questions, is a regular feature in application developer interviews, be ready to tackle it with the approach mentioned.