当前位置:网站首页>Go basic data types: characters and strings
Go basic data types: characters and strings
2022-06-29 06:26:00 【Yi Yue Wang Chao】
go Chinese characters and strings are different in nature .‘a’ Is the character ,“a” Is string .
python There is no concept of characters in , All strings .
go Example :
package main import "fmt" func main() { a := 'a' fmt.Printf("%T\n", a) fmt.Println(a+3) //'a' The essence is int, So you can add fmt.Println("*******************") b := "b" fmt.Printf("%T", b) }Running results :
int32 100 ******************* string
边栏推荐
- How to combine two byte arrays [repeat] - how to combine two byte arrays [duplicate]
- 2022.02.14
- Meso tetra (4-N, N, n-trimethylaminophenyl) porphyrin (ttmapp) /meso tetra - [4- (BOC threonine) aminophenyl] porphyrin (TAPP thr BOC) supplied by Qiyue
- Ctrip launched the "3+2" office mode. Are you sour?
- Fault: KDC warning log for id29
- Servlet version conflict causes page 404
- Is there any difference between a=a+b and a+=b?
- Purple red solid meso tetra (o-alkoxyphenyl) porphyrin cobalt (meso-t (2-rop) PCO) / tetra (n, n-diphenyl-p-amino) phenyl porphyrin (tdpatph2)
- Can I cast int to a variable of type byte? What happens if the value is larger than the range of byte type?
- Venn diagram proportional and color shading with semi transparency
猜你喜欢

Slot

What has urbanization brought to our mental health and behavior?

Problems with MySQL database query

Maximum ascending subarray sum of leetcode simple problem

Longest substring between two identical characters of leetcode simple question

Programming specification and variables of shell script

Rich material libraries make modeling easy and efficient for developers

MySQL learning notes

Fault: KDC warning log for id29

Pytest (7) -yield and termination function
随机推荐
Honeypot based on MySQL load data local INFILE
Loosely matched jest A value in tohavebeencalledwith - loose match one value in jest toHaveBeenCalledWith
2022-01 Microsoft vulnerability notification
Installing modules in pycharm
Activiti Designer
Fault: KDC warning log for id29
Week 10 - task 0- execution process instance resolution of constructors and destructors
Overlay histogram with density curve
How to use regex in file find
After “Go to Definition”, is there a command to return to where you came from?
Go compile source code (window environment)
Maximum ascending subarray sum of leetcode simple problem
5- (4-benzoimide phenyl) - 10,15,20-triphenylporphyrin (battph2) and its Zn complex (battpzn) / tetra (4-aminophenyl) porphyrin (tapph2) Qiyue supply
5,10-di (4-aminophenyl) - 15,20-diphenylporphyrin (cis-dadph2) /5,15-di (4-aminophenyl) - 10,20-diphenylporphyrin (trans-dadph2) / (tri-apph2) supplied by Qiyue
Jenkins operation Chapter 6 mail server sending build results
Venn diagram proportional and color shading with semi transparency
There are two ways for golang to develop mobile applications
Pointer from beginner to advanced (2)
How to change the password after forgetting the MySQL password (the latest version of 2022 detailed tutorial nanny level)
Difference between static and final