D. Cube
time limit per test
1 second
memory limit per test
256 megabytes
input
standard input
output
standard output
Help, I tried to microwave a chocolate bar and now there's just chocolate everywhere.
— Evil Neuro

Evil Neuro loves cubes!

Inside the $$$n \times n \times n$$$ electronic toy chest, Evil controls cubes, each occupying a $$$1 \times 1 \times 1$$$ coordinate within the grid. Since the cubes are digital, they can defy gravity and float in mid-air. That is to say, Evil can place them anywhere inside the chest.

Evil wants the chest to look completely packed. To pull it off, the arrangement must be filled from every angle. Whether viewed from the front, the side, or above, the chest must appear as a solid $$$n \times n$$$ block, with no space left.

Unfortunately, Evil has a limited supply of cubes. She asks you to help her do this using the minimum number of cubes.

Input

The first and only line contains a single integer $$$n$$$ $$$(1\le n\le 200)$$$ — the size of the chest.

Output

First, print an integer $$$k$$$, indicating the minimum number of cubes required.

Then, print $$$k$$$ lines, each containing three integers $$$x, y, z\ (1\le x,y,z \le n)$$$, indicating the coordinates of the cube.

If there exist multiple answers, output any of them.

Example
Input
2
Output
4
1 1 2
1 2 1
2 1 1
2 2 2
Note

One possible construction of the sample is shown below: