当前位置:网站首页>Goto statements
Goto statements
2022-07-30 08:03:00 【Code Writers】
The goto statement in C language can only be used in the same function segment
The usage is as follows:
goto: label; // to the label position
label:
The role of the goto statement in the figure below is equivalent to the break statement.
Java continues to use the tag mechanism, but it is different from C's goto statement usage:
Java's goto statement can only be used in loops
Use with break
Labeled break will break and break out of the loop pointed to by the label.Use with continue
A tagged continue will reach the position of the tag and re-enter the loop immediately following the tag.
The abuse of the goto statement can easily lead to confusion in the logical structure of the code and increase the difficulty of reading the code. Therefore, the goto statement is generally used less in the C language and less in the Java language.
边栏推荐
- golang : Zap日志整合
- Process and Scheduled Task Management
- Mobile phone side scroll to page to specify location
- Is it possible to use the same port for UDP and TCP?
- DNS domain name resolution services
- Electron使用romote报错 : Uncaught TypeError: Cannot read property ‘BrowserWindow‘ of undefined
- interface
- @Bean 与 @Component 用在同一个类上,会怎样?
- sql concat()函数
- 【MySQL】MySQL中如何实现分页操作
猜你喜欢

Equation Derivation Proof of Vector Triple Product
![[硬核干货]由0到1,突破信息系统项目管理师(呕心沥血经验之谈)!!!](/img/9a/f3e4bdd0ce8ec153a8e6bdbff5647e.jpg)
[硬核干货]由0到1,突破信息系统项目管理师(呕心沥血经验之谈)!!!

Camera coordinate system, world coordinate system, pixel coordinate system conversion, and Fov conversion of OPENGLDEFocal Length and Opengl

STL源码剖析:迭代器的概念理解,以及代码测试。

Redis下载与安装

DNS domain name resolution services

PXE efficient mass network capacity

Go 使用 freecache 缓存

AI can identify race from X-rays, but no one knows why

CTO说不建议我使用SELECT * ,这是为什么?
随机推荐
goto语句
分布式系统中的开创者—莱斯利·兰伯特
万能js时间日期格式转换
向量叉乘的几何意义及其模的计算
2020年度总结——品曾经,明得失,展未来
What new materials are used in the large aircraft C919?
DNS domain name resolution services
this与super
B站崩了,如果是你是那晚负责的开发人员你会怎么做?
新人误删数据,组长巧用MySQL主从复制延迟挽回损失
和AI一起玩儿剧本杀:居然比我还入戏
2020 数学建模之旅
Station B collapsed, what would you do if you were the developer in charge that night?
MySQL主从复制配置搭建,一步到位
sql concat()函数
The usage of window.open(), js opens a new form
export , export default,import完整用法
Graphical relational database design ideas, this is too vivid
golang: Gorm配置Mysql多数据源
Redis下载与安装