A body of mass M starting from rest from origin moves along x axis with constant power p calculate relation between velocity/distance

please explain it...

sir,why in solution we cannot find direct value of x BY PUTTING VALUE OF TIME T(given) IN GIVEN EQUATION OF x?...i do not understand the solution given..explain me.

Qsn n 2

In this question particles hits the ground with speed v^2=2gH

When it hits the sand it starts deceleration F/m

According to the formula V^2-U^2=2(deceleration)x

Solving this we get mgh/F as answers !!!! Then why using energy theoram