package main import "fmt" func main() { s := "abc" // s[0] is the byte value 97 fmt.Println(s[0]) // %c formats it back to the character fmt.Printf("%c\n", s[0]) }
s[i] is a byte, not a character