Magure Softwares interview question

Javascript higher order function like map, filter