The first transformation displayed is a 90° clockwise rotation about the vertex (4, -9).
The second transformation is a shift of 5 units up and 5 units left.
How did we determine these transformations?
Basically, because Figure P has perpendicular sides which allows us to see that the rotation was 90°. The vertical side changed to a horizontal side.
After that first transformation, we just matched the vertices of Figure P with the vertices of Figure Q.