Question 7
Back to Exercise
Which of these is a higher-order function?
- A A function declared at the top of a file
- B A function with more than three parameters
- C A function that takes a function as an argument or returns a function Correct
- D A function that calls itself
Correct Answer: Option C
map, filter, reduce, setTimeout and function factories are higher-order. A function that calls itself is recursive.
Discussion & Comments 0
Share your method, a shortcut, or ask about a step you didn't follow.
No comments yet. Be the first to share your solution!