![](https://img-blog.csdnimg.cn/20201014180756724.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
leetcode
medchest
这个作者很懒,什么都没留下…
展开
-
Leetcode[119] PascalII
#include#includeusing namespace std;class Solution{public: Solution(); ~Solution(); vector getRow(int rowIndex) { vector res(1, 1); for (int i = 1; i <= rowIndex; i++){ res.push_back(1原创 2015-04-22 10:00:13 · 345 阅读 · 0 评论 -
Leetcode[118] Pascal
11 11 2 11 3 3 11 4 6 4 11.初始化numRows行(先得判定numRows是不是为0)2.每一行的元素,特殊元素:第一个和最后一个为13.每一行的元素,普通元素:其余元素为上面的左边和右边vector > generate(int numRows) { vector > res; if (numRows == 0)return re原创 2015-04-22 21:08:23 · 233 阅读 · 0 评论