Definition:Chess/Rules/Castling

Definition
Castling is a special move where, in one move, the king moves two squares towards a rook, and the rook jumps over the king and lands on the next square the other side of the king.

This can only be done if:
 * $(1): \quad$ The king and rook are both in their initial positions.
 * $(2): \quad$ The squares in between the king and rook are empty.
 * $(3): \quad$ The king is not in check, and neither of the $2$ squares it moves through are under attack.