Merge pull request #2354 from hlp777/patch-1

Update 0300.最长上升子序列.md
This commit is contained in:
程序员Carl 2023-12-07 13:00:33 +08:00 committed by GitHub
commit 7d70f5155f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -130,7 +130,7 @@ public:
class Solution {
public int lengthOfLIS(int[] nums) {
int[] dp = new int[nums.length];
int res = 0;
int res = 1;
Arrays.fill(dp, 1);
for (int i = 1; i < dp.length; i++) {
for (int j = 0; j < i; j++) {