摘要: 从下面往上 可以建立一个cache 这个点往下search过已经知道最小值了 下一次访问的时候就可以直接取值, 因为一般一个点都会被上面访问两次,如果不这样就会time limit错误 阅读全文
posted @ 2018-09-22 23:37 jasoncool1 阅读(85) 评论(0) 推荐(0) 编辑
摘要: 1 class Solution { 2 List res = new ArrayList(); 3 public List getRow(int rowIndex) { 4 helper(1, rowIndex + 1, new ArrayList(), null); 5 return res; 6 7 }... 阅读全文
posted @ 2018-09-22 04:29 jasoncool1 阅读(141) 评论(0) 推荐(0) 编辑
摘要: 1 class Solution { 2 List> res = new ArrayList(); 3 public List> generate(int numRows) { 4 helper(1, numRows, new ArrayList(), null); 5 return res; 6 7 }... 阅读全文
posted @ 2018-09-22 00:25 jasoncool1 阅读(96) 评论(0) 推荐(0) 编辑