mirror of
https://github.com/youngyangyang04/leetcode-master.git
synced 2025-07-08 08:50:15 +08:00
修改 0392.判断子序列.md Go二维DP格式
修改 0392.判断子序列.md Go二维DP格式
This commit is contained in:
@ -250,7 +250,7 @@ func isSubsequence(s string, t string) bool {
|
||||
}
|
||||
for i := 1; i < len(dp); i ++{
|
||||
for j := 1; j < len(dp[i]); j ++{
|
||||
if s[i - 1] == t[j-1] {
|
||||
if s[i - 1] == t[j - 1] {
|
||||
dp[i][j] = dp[i - 1][j - 1] +1
|
||||
}else{
|
||||
dp[i][j] = dp[i][j - 1]
|
||||
|
Reference in New Issue
Block a user