Because functions are values, functions can return other functions. This can be incredibly powerful.
Remember there's a difference between a function and a function applied to its arguments. It's the difference between f and f(x). If a function doesn't take any arguments there is still a difference. makeFunction is a function that takes no arguments, makeFunction() is the result of calling that function. Which is itself another function...
Define a function named generate that takes one argument, a function f. It should return an array that consists of the function f and another function that doubles its input.