Given the point P with the coordinate indicated below
When a point is reflected across the line y=x, the transformation rule is shown below:
From the above transformation rule, we see that the coordinate will be swapped for reflection over the line y = x.
Thus, the coordinate of Q is shown below.
Hence, the coordinates of point Q is ( b , a )
The second option is the correct option.