mirror of
https://github.com/golang/go
synced 2024-11-22 05:14:40 -07:00
strings: make Count example show results
Thanks to dr.volker.dobler for tracking this down. Filed a long-term issue (3142) which may eventually resolve this problem w/o the need for a manual fix. R=iant CC=golang-dev https://golang.org/cl/5698078
This commit is contained in:
parent
ab169c6e3f
commit
b495e5c538
@ -41,6 +41,7 @@ func ExampleContainsAny() {
|
||||
func ExampleCount() {
|
||||
fmt.Println(strings.Count("cheese", "e"))
|
||||
fmt.Println(strings.Count("five", "")) // before & after each rune
|
||||
|
||||
// Output:
|
||||
// 3
|
||||
// 5
|
||||
|
Loading…
Reference in New Issue
Block a user