string
UTF-8编译
编号 | 编码模板 |
---|---|
[0,127] | 0??????? |
[128,2047] | 110????? 10?????? |
[2048,65535] | 1110???? 10?????? 10?????? |
fmp.Printf("%c\n",str[2])
str[2]='0' //error
bs:=([]byte)(str)
bs[2]='o'
fmp.Printf("%c\n",bs[2])
编号 | 编码模板 |
---|---|
[0,127] | 0??????? |
[128,2047] | 110????? 10?????? |
[2048,65535] | 1110???? 10?????? 10?????? |
fmp.Printf("%c\n",str[2])
str[2]='0' //error
bs:=([]byte)(str)
bs[2]='o'
fmp.Printf("%c\n",bs[2])