Our modern maths readily provides the answer to this ancient question. When shooting a projectile, what is the optimal angle that will maximise the range?
Some trigonometry and Newtonian mechanics provides the answer. 45 degrees.
I would be surprised if it wasn't figured out before trigonomrty.
Who first and how ever figured it out?