当前位置:网站首页>【day03】流程控制语句
【day03】流程控制语句
2022-07-28 04:01:00 【饮马翰海】
01_流程概述与顺序结构


02_选择结构_单if语句(有或者无)


03_选择结构_标准if-else语句(二者选其一)
这种格式当中,它不会两个都执行的,也不会两个都不执行的,一定是从两种情况当中选择一种进行执行,是两者选其一的。

04_选择结构_扩展if-else语句(N者选其一)
如果都不符合,else做收尾工作

一定是在前一个条件不满足的情况下,我再进行下一个条件的判断。那么它不再是二者选其一,而是n者选其一。
05_练习_用if语句实现考试成绩划分

06_练习_用if语句替换三元运算符
07_选择结构_标准的switch语句


08_选择结构_穿透的switch语句
如果default向上移动,没有break,会发生穿透
09_循环结构_循环概述与基本组成部分
循环是让计算机做一些重复性的东西

10_循环结构_for循环


11_循环结构_while循环



12_循环结构_do-while循环
while小括号后面有一个分号
do-while语句,第一次执行是无条件执行的。不管你的循环条件是多少,我至少执行一次

13_练习_用循环求出1-100之间的偶数和
14_三种循环的区别
15_循环控制_break语句
16_循环控制_continue语句
17_死循环
要想强制停止死循环,按一下Ctrl+C

18_循环嵌套


边栏推荐
- 静态博客搭建工具汇总
- CANopen learning notes
- Redis cluster
- Prefix-Tuning: Optimizing Continuous Prompts for Generation
- Regression - linear regression
- cookie与Session
- [MySQL database] index and transaction (often used in interview)
- Selenium--WEB自动化测试工具
- Skillfully use stack backtracking to help you quickly locate problems
- What is interface testing and its testing process
猜你喜欢

静态博客搭建工具汇总

Iterator function operation of iterator learning

【LeetCode】34、在排序数组中查找元素的第一个和最后一个位置

21 days, fat brother personally takes you to play oauth2

Filters, interceptors, listeners

Data mining-01
![[untitled]](/img/6c/df2ebb3e39d1e47b8dd74cfdddbb06.gif)
[untitled]

高等数学(第七版)同济大学 习题3-4 个人解答(前8题)

Crowdfunding platform system based on JSP & Servlet

Linux - MySQL advanced (day19)
随机推荐
CANopen learning notes
Dynamic programming - 474. One and zero
Chinese Remainder Theorem of X problem
STC timer is abnormal (how to modify the initial value, the timing time is 100ms)
企业数字化建设“三不五要”原则
Istio's Traffic Management API
LightPicture – 精致图床系统
WordPress simple mkblog blog theme template v2.1
Detailed explanation of pointer written test questions (C language)
Dynamic planning - 1049. Weight of the last stone II
TypeError: ufunc ‘bitwise_ and‘ not supported for the input types, and the inputs could not be safely
[prototype and prototype chain] get to know prototype and prototype chain~
Leetcode58. 最后一个单词的长度
[Luogu p4590] garden party (DP set DP)
Read Plato farm's eplato and the reason for its high premium
Advanced Mathematics (Seventh Edition) Tongji University exercises 3-4 personal solutions (first 8 questions)
Redis cluster
[openvx] VX for basic use of objects_ distribution
Move notice!
一名合格的软件测试工程师,应该具备哪些技术能力?