This commit is contained in:
krahets
2023-08-08 23:15:13 +08:00
parent 48adefba25
commit 6d41b5da04
11 changed files with 350 additions and 150 deletions

View File

@@ -109,7 +109,9 @@ comments: true
=== "Rust"
```rust title="array.rs"
/* 初始化数组 */
let arr: Vec<i32> = vec![0; 5]; // [0, 0, 0, 0, 0]
let nums: Vec<i32> = vec![1, 3, 2, 5, 4];
```
## 4.1.1. &nbsp; 数组优点