#T488. 走台阶
走台阶
Description
There is a 1×n rectangular grid to be completely tiled using 1×1, 1×2, and 1×3 dominoes. For example, when n=3, it's a 1×3 grid. In this case, there are four ways to tile the grid using 1×1, 1×2, and 1×3 dominoes, as shown in the following figure:
A positive integer n, representing a 1×n rectangular grid, where 0 < n <= 30. A number indicating the total number of tiling methods. CodesOnline
Input Format
Output Format