Correctly name the type of the input in reduce's implementation.