Reef Technologies interview question

The technical test is very specific, needs a strong knowledge based on higher-order functions