mirror of
https://github.com/duke-git/lancet.git
synced 2026-02-07 06:02:27 +08:00
feat: add FindAllOccurrences
This commit is contained in:
@@ -763,5 +763,13 @@ func ExampleExtractContent() {
|
||||
|
||||
// Output:
|
||||
// [content1 content2 content1]
|
||||
|
||||
}
|
||||
|
||||
func ExampleFindAllOccurrences() {
|
||||
result := FindAllOccurrences("ababab", "ab")
|
||||
|
||||
fmt.Println(result)
|
||||
|
||||
// Output:
|
||||
// [0 2 4]
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user