Update chapter_2.md

This commit is contained in:
令狐一冲
2023-05-17 10:50:29 +08:00
committed by GitHub
parent 14feebe07f
commit 50d623011d

View File

@@ -142,7 +142,7 @@ Rust使用Cargo作为官方的构建工具和包管理器下面通过Cargo创
```cargo new hello_world``` ```cargo new hello_world```
创建后,可以看到整个目录的结构如下: 创建后,可以看到整个目录的结构如下:
[图片] ![目录结构](assets/62.PNG)
其中Cargo.toml是项目的配置文件src为源代码目录main.rs为主程序文件。 其中Cargo.toml是项目的配置文件src为源代码目录main.rs为主程序文件。
### 2.3.2 编写程序 ### 2.3.2 编写程序
@@ -163,7 +163,7 @@ cd hello_world
cargo run cargo run
``` ```
运行结果如下: 运行结果如下:
[图片] ![目录结构](assets/63.PNG)
### 2.3.4 理解Rust源码的基本结构 ### 2.3.4 理解Rust源码的基本结构
下面简单介绍Rust源码的结构。 下面简单介绍Rust源码的结构。