Golang strings.ContainsRune() function example
package strings
Golang strings.ContainsRune() function usage example
package main
import (
"fmt"
"strings"
)
func main() {
ok := strings.ContainsRune("Hello World!", 'e')
fmt.Println("Hello World contains the rune e :", ok)
ok = strings.ContainsRune("Hello World!", '제')
fmt.Println("Hello World contains the rune 제 :", ok)
}
Reference :
Advertisement
Something interesting
Tutorials
+7.8k Golang : Regular Expression find string example
+4.6k JavaScript : Rounding number to decimal formats to display currency
+22.4k Golang : How to read JPG(JPEG), GIF and PNG files ?
+24.6k Golang : How to validate URL the right way
+27.7k PHP : Count number of JSON items/objects
+6.7k Golang : Derive cryptographic key from passwords with Argon2
+19.5k Golang : How to Set or Add Header http.ResponseWriter?
+33.7k Golang : All update packages with go get command
+6.2k Golang : Extract XML attribute data with attr field tag example
+10.2k Golang : Use regular expression to get all upper case or lower case characters example
+10.6k Golang : Select region of interest with mouse click and crop from image
+34k Golang : Proper way to set function argument default value