Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit6ec2fe6

Browse files
authored
Update longest_increasing_subsequence.md
Small improvement of the wording of a question
1 parente8b714d commit6ec2fe6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

‎src/sequences/longest_increasing_subsequence.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,7 @@ We will again gradually process the numbers, first $a[0]$, then $a[1]$, etc, and
174174
$$
175175

176176
When we process $a[i]$, we can ask ourselves.
177-
What have theconditionsto be, that we write the current number $a[i]$ into the $d[0 \dots n]$ array?
177+
Under whatconditionsshould we write the current number $a[i]$ into the $d[0 \dots n]$ array?
178178

179179
We set $d[l] = a[i]$, if there is a longest increasing sequence of length $l$ that ends in $a[i]$, and there is no longest increasing sequence of length $l$ that ends in a smaller number.
180180
Similar to the previous approach, if we remove the number $a[i]$ from the longest increasing sequence of length $l$, we get another longest increasing sequence of length $l -1$.

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp