Reflection across y=x

Click and drag the blue dot to see it's reflection across the line y=x (the green dot). Pay attention to the coordinates. How are they related to each other?

Information: Reflection across y=x