Skip to content

Commit a622f4f

Browse files
committed
修改文件: DynamicProgram/300-longest-increasing-subsequence.md
1 parent 923f4a4 commit a622f4f

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

DynamicProgram/300-longest-increasing-subsequence.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ grammar_cjkRuby: true
2222
for (int j = 0 ; j < i; j ++)
2323
if (nums[i] > nums[j] && lens[j] > bigger)
2424
bigger = lens[j];
25-
lens[i] = bigger + 1;
25+
lens[i] = bigger + 1;//这里设置的比较巧妙,当i是递增序列中的第一个元素的时候,依然是成立的
2626
}
2727
//找到lens数组中的最大值;
2828
int maxLen = 0;

0 commit comments

Comments
 (0)