Exam-style question
Try this first
Which situation demonstrates a function being used as an argument?.
- A.A function is supplied to another function as one of the values it receives
- B.A function is written as a comment
- C.A function is replaced by a character
- D.A function is used only to display a message
Model answer
What a good answer should say
- A function is supplied to another function as one of the values it receives
Explanation
Why this works
A first-class function can be assigned as an argument, meaning it can be supplied to another function as a value it receives.
Common mistake
No common mistake is linked to this question yet.
