Refining Ch03.

This commit is contained in:
rust-lang.xfoss.com
2023-12-08 14:39:07 +08:00
parent 82e42ad6cf
commit f413255aae
2 changed files with 43 additions and 19 deletions

View File

@@ -1,3 +1,7 @@
fn main() {
let guess = "42".parse().expect("这不是个数字!");
let c = 'z';
let z: char = ''; // 带有显式的类型注解
let heart_eyed_cat = '😻';
println! ("c 为 {c}, z 为 {z}, 爱心猫{heart_eyed_cat}");
}