Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/VanjaRo/LeetCode
/ isSubsequence
Function
isSubsequence
tasks/392.go:9–17 ·
view source on GitHub ↗
(s string, t string)
Source
from the content-addressed store, hash-verified
7
}
8
9
func
isSubsequence(s string, t string) bool {
10
left := 0
11
for
i := 0; i < len(t) && left < len(s); i++ {
12
if
t[i] == s[left] {
13
left++
14
}
15
}
16
return
left == len(s)
17
}
Callers
1
main
Function · 0.85
Calls
no outgoing calls
Tested by
no test coverage detected