CF1182A.Filling Shapes

传统题 时间 2000 ms 内存 256 MiB 5 尝试 1 已通过 1 标签

Filling Shapes

You have a given integer nn. Find the number of ways to fill all 3×n3 \times n tiles with the shape described in the picture below. Upon filling, no empty spaces are allowed. Shapes cannot overlap.

This picture describes when n=4n = 4. The left one is the shape and the right one is 3×n3 \times n tiles.

Input

The only line contains one integer nn (1n601 \le n \le 60) — the length.

Output

Print the number of ways to fill.

Note

In the first example, there are 44 possible cases of filling.

In the second example, you cannot fill the shapes in 3×13 \times 1 tiles.

Samples

4
4
1
0

在线编程 IDE

建议全屏模式获得最佳体验