A baseball thrown at an angle of 45 degrees above the horizontal strikes a building 18 m away at a point 8 m above the point it is thrown. Find the time taken by the ball to hit the building.

Can someone please show me how to set the problem up?