当前位置:网站首页>Basic data types in golang
Basic data types in golang
2022-07-04 09:16:00 【The diligent bird that flies first】
Note: matters needing attention
- Get the length of the object built in len() The length returned by the function can vary according to the byte length of different platforms .
- In practice , Slice or map The number of elements can be used int To express . When it comes to binary transmission 、 When reading and writing the structure description of a file , In order to keep the structure of the file unaffected by the byte length of different compiled target platforms , Do not use int and uint.
- Go Casting integers to Booleans... Is not allowed in the language .
- Boolean cannot participate in numeric operations , It can't be converted with other types .
- Go There are only casts in the language , There is no implicit type conversion . This syntax can only be used when mutual conversion is supported between two types .
- stay Go in , The essence of a character is an integer , When output directly , Is the character corresponding to UTF-8 The code value of the code .
边栏推荐
- 2022-2028 global edible probiotic raw material industry research and trend analysis report
- Flutter 小技巧之 ListView 和 PageView 的各种花式嵌套
- Global and Chinese markets for laser assisted liposuction (LAL) devices 2022-2028: Research Report on technology, participants, trends, market size and share
- A subclass must use the super keyword to call the methods of its parent class
- "How to connect the network" reading notes - Web server request and response (4)
- Launpad | 基础知识
- Investment analysis and future production and marketing demand forecast report of China's paper industry Ⓥ 2022 ~ 2028
- Langage C - démarrer - base - syntaxe - [opérateur, conversion de type] (vi)
- C语言-入门-基础-语法-[标识符,关键字,分号,空格,注释,输入和输出](三)
- awk从入门到入土(8)数组
猜你喜欢

【LeetCode 42】501. Mode in binary search tree

2022-2028 global industry research and trend analysis report on anterior segment and fundus OTC detectors

Turn: excellent managers focus not on mistakes, but on advantages

Codeforces Round #793 (Div. 2)(A-D)

2022-2028 global visual quality analyzer industry research and trend analysis report

2022-2028 global special starch industry research and trend analysis report

Relationship and operation of random events

Some points needing attention in PMP learning

How to ensure the uniqueness of ID in distributed environment
![Reload CUDA and cudnn (for tensorflow and pytorch) [personal sorting summary]](/img/3f/a71b56a62d2a0d64749a6af05384f5.jpg)
Reload CUDA and cudnn (for tensorflow and pytorch) [personal sorting summary]
随机推荐
GoLand environment variable configuration
随机事件的关系与运算
ArrayBuffer
Flutter 小技巧之 ListView 和 PageView 的各种花式嵌套
Launchpad x | mode
Awk from getting started to digging in (9) circular statement
awk从入门到入土(8)数组
Simulate EF dbcontext with MOQ - mocking EF dbcontext with MOQ
What is permission? What is a role? What are users?
Awk from entry to earth (14) awk output redirection
Research and investment strategy report of China's electronic hydrogen peroxide industry (2022 Edition)
Global and Chinese market of bipolar generators 2022-2028: Research Report on technology, participants, trends, market size and share
awk从入门到入土(12)awk也可以写脚本,替代shell
Horizon sunrise X3 PI (I) first boot details
26. Delete duplicates in the ordered array (fast and slow pointer de duplication)
2022-2028 global small batch batch batch furnace industry research and trend analysis report
AMLOGIC gsensor debugging
2022-2028 global optical transparency industry research and trend analysis report
Research Report on the current market situation and development prospects of calcium sulfate whiskers in China (2022 Edition)
Report on the development trend and prospect trend of high purity zinc antimonide market in the world and China Ⓕ 2022 ~ 2027