Codeforces Round 566 (Div. 2)
翻译中…
You have a given integer $n$. Find the number of ways to fill all $3 \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 = 4$. The left one is the shape and the right one is $3 \times n$ tiles.
翻译中…
Input
翻译中…
The only line contains one integer $n$ ($1 \le n \le 60$) — the length.
翻译中…
Output
翻译中…
Print the number of ways to fill.
翻译中…
Note
翻译中…
In the first example, there are $4$ possible cases of filling.
翻译中…
In the second example, you cannot fill the shapes in $3 \times 1$ tiles.
翻译中…
样例
Input #1
4
Output #1
4
InputCopy
OutputCopy
Input #2
1
Output #2
0
InputCopy
OutputCopy
题目信息
标签
动态规划
数学
题面与样例版权归 Codeforces 及出题人所有;中文翻译由 AI 生成(CI 管线),如有出入请以原文为准。