mirror of
https://github.com/RustyCab/LearnRustEasy.git
synced 2026-02-03 10:13:23 +08:00
update chapter 3.5 heading
This commit is contained in:
@@ -7,7 +7,7 @@ Rust中的控制流结构主要包括:
|
||||
- `while`循环;
|
||||
- `for .. in` 循环。
|
||||
|
||||
## 3.5.1. if条件判断
|
||||
## 3.5.1 if条件判断
|
||||
|
||||
- `if`执行条件判断,示例如下:
|
||||
|
||||
@@ -67,7 +67,7 @@ Rust中的控制流结构主要包括:
|
||||
}
|
||||
```
|
||||
|
||||
## 3.5.2. loop循环
|
||||
## 3.5.2 loop循环
|
||||
|
||||
- loop重复执行代码
|
||||
|
||||
@@ -134,7 +134,7 @@ Rust中的控制流结构主要包括:
|
||||
}
|
||||
```
|
||||
|
||||
## 3.5.3. while条件循环
|
||||
## 3.5.3 while条件循环
|
||||
|
||||
- `while`条件循环执行代码,当条件不满足时结束循环,如下:
|
||||
|
||||
@@ -167,7 +167,7 @@ Rust中的控制流结构主要包括:
|
||||
}
|
||||
```
|
||||
|
||||
## 3.5.4. `for .. in` 循环
|
||||
## 3.5.4 `for .. in` 循环
|
||||
|
||||
`for`循环用来对一个集合的每个元素执行一些代码,使用方式如下:
|
||||
|
||||
|
||||
Reference in New Issue
Block a user