mirror of
https://github.com/KaiserY/trpl-zh-cn
synced 2025-05-01 02:38:35 +08:00
13 lines
221 B
Rust
13 lines
221 B
Rust
|
fn main() {
|
||
|
// ANCHOR: here
|
||
|
let x = 1;
|
||
|
|
||
|
match x {
|
||
|
1 => println!("one"),
|
||
|
2 => println!("two"),
|
||
|
3 => println!("three"),
|
||
|
_ => println!("anything"),
|
||
|
}
|
||
|
// ANCHOR_END: here
|
||
|
}
|