AdvancedRating 1700
Tiling a 3 × n Board
Count the ways to tile a 3 × n board with 2 × 1 dominoes, modulo 1 000 000 007.
Input
One integer n (1 ≤ n ≤ 10⁵).
Output
One integer.
Sample 1
Input
2
Output
3
Sample 2
Input
1
Output
0
Output appears hereOne integer n (1 ≤ n ≤ 10⁵).
One integer.
2
3
1
0
Output appears here