Step 1: Finding the initial vertical velocity.
Time taken to reach maximum height is given as $2\,\text{s}$.
For vertical motion,
\[ u_y = g t \] \[ u_y = 10 \times 2 = 20\,\text{m s}^{-1} \] Step 2: Writing the vertical displacement equation.
The ball lands on the roof after $3\,\text{s}$.
Vertical displacement after time $t$ is given by:
\[ y = u_y t - \frac{1}{2} g t^2 \] Step 3: Substituting values to find height $H$.
\[ H = (20 \times 3) - \frac{1}{2} \times 10 \times (3)^2 \] \[ H = 60 - 45 \] \[ H = 15\,\text{m} \] Step 4: Final conclusion.
The height of the building on which the ball lands is $15\,\text{m}$.