Ryan and Natalya are having an argument about who can throw a shot-put farther. Early one foggy morning they bring some shot-puts outside to a large, open, level field. However there is a bit of a problem - the morning fog is so thick that after thowing the shot-put very far, they lose track of it and are unable to find it again! Luckily they can still hear when the shot-puts land, so it should still be possible for them to calculate who has thrown farther.
You will be given two values - the total initial velocity V of the projectile, and the
total time T that the projectile is in the air before reaching the ground.
Assume that
the "launch" and "landing" heights are equal, and ignore any factor of air resistance.
Assume acceleration due to gravity is constant g = -9.8 m/s^2
Input Data
First line will be Q, the quantity of testcases.
Q lines will then follow, each with two space-separated values V T, in units of
meters per second and seconds respectively.
Answer
Should consist of Q space-separated values corresponding to the distances travelled
by each projectile, in meters.
Error should be less than 1e-6.
Example
input data:
2
9.876 1.234
98.765 2.345
answer:
9.635794 230.031157