<image>Unit squares of a squared board $2 \times 3$ are coloured black and white like a chessboard (see picture). Determine the minimum number of steps necessary to achieve the reverse of the left board, following the rule: in each step, we must repaint two unit squares that have a joint edge, but we must repaint a black square with green, a green square with white and a white square with black.