变态跳台阶

思路:仍是跟跳台阶的思路一致,不过此次不是分两种状况,而是分n种,也就是加个for循环就能够了。code class Solution { public: int jumpFloorII(int number) { int* a = new int[number+1]; if(number<=0) return 0; if(number==1
相关文章
相关标签/搜索