摘要:
Given a triangle, find the minimum path sum from top to bottom. Each step you may move to adjacent numbers on the row below.(Medium) For example, give 阅读全文
摘要:
Given an index k, return the kth row of the Pascal's triangle. (Easy) For example, given k = 3,Return [1,3,3,1]. Note:Could you optimize your algorith 阅读全文
摘要:
Given numRows, generate the first numRows of Pascal's triangle. For example, given numRows = 5, (Easy)Return 分析: 求解杨辉三角形,按照其定义以此求解即可,注意优化写法使其能够更简洁(比如对 阅读全文