P******r 发帖数: 842 | 1 Given a triangle, find the minimum path sum from top to bottom. Each step
you may move to adjacent numbers on the row below.
这个adjacent numbers是不是i和i+1(pass oj)。要是做i-1,i,i+1不pass。 | l********t 发帖数: 878 | 2 In the original graph, adjacent means position 1/2 is adjacent to 0 and 1;
when you program, yes, it means i and i+1, but i-1 not included. | P******r 发帖数: 842 | 3 恩,明白了。这样的话,logic简单些,code容易写一些。谢谢。
【在 l********t 的大作中提到】 : In the original graph, adjacent means position 1/2 is adjacent to 0 and 1; : when you program, yes, it means i and i+1, but i-1 not included.
|
|