- Sort Score
- Result 10 results
- Languages All
Results 1 - 1 of 1 for ExampleCutPrefix (0.08 sec)
-
src/bytes/example_test.go
// Output: // Cut("Gopher", "Go") = "", "pher", true // Cut("Gopher", "ph") = "Go", "er", true // Cut("Gopher", "er") = "Goph", "", true // Cut("Gopher", "Badger") = "Gopher", "", false } func ExampleCutPrefix() { show := func(s, prefix string) { after, found := bytes.CutPrefix([]byte(s), []byte(prefix)) fmt.Printf("CutPrefix(%q, %q) = %q, %v\n", s, prefix, after, found) } show("Gopher", "Go")
Registered: Tue Sep 09 11:13:09 UTC 2025 - Last Modified: Mon May 12 16:07:54 UTC 2025 - 16.5K bytes - Viewed (0)