Deriving A Motion Equation

1. The problem statement, all variables and given/known data
Derive algebraic expressions for the range and total time-of-flight of a projectile launched with initial speed v, from a height h, and at an angle Q, above the horizontal. We were given the final equations but I am unsure of how to derive them.

2. Relevant equations
range=vt-.5gt^2, where g is the acceleration due to gravity and t is the time in seconds.

time= (vsinQ+((vsinQ)^2+2gh)^.5)/g

3. The attempt at a solution
Considering the ball, after it has been launched:
Fx=0
Vox=vcosQ
Fy=mg
Voy=vsinQ