mirror of
https://github.com/youngyangyang04/leetcode-master.git
synced 2025-07-06 23:28:29 +08:00
Update 0674.最长连续递增序列.md
typo
This commit is contained in:
@ -52,7 +52,7 @@
|
||||
|
||||
**注意这里就体现出和[动态规划:300.最长递增子序列](https://programmercarl.com/0300.最长上升子序列.html)的区别!**
|
||||
|
||||
因为本题要求连续递增子序列,所以就必要比较nums[i]与nums[i - 1],而不用去比较nums[j]与nums[i] (j是在0到i之间遍历)。
|
||||
因为本题要求连续递增子序列,所以就只要比较nums[i]与nums[i - 1],而不用去比较nums[j]与nums[i] (j是在0到i之间遍历)。
|
||||
|
||||
既然不用j了,那么也不用两层for循环,本题一层for循环就行,比较nums[i] 和 nums[i - 1]。
|
||||
|
||||
|
Reference in New Issue
Block a user