I think I agree with you. I would argue that the mathematical ability needed to solve the question above is to realize how to phrase a query to google, find the resulting formula, and turn it into code. You don't need to be able to derive it, for the vast majority of jobs out there.
Also: I've noticed that most programming is equivalent to what in grade school and high school they called a "word problem". Most of the class would groan when we had to do these; I loved them. I suspect if you struggled with word problems, you would have a hard time programming.