数组和集合 / 迭代器
简单迭代器
反向迭代器
let
list = [
1
,
2
,
3
];
let
iterator = list.
iter
();
for
x
in
iterator {
println!
(
"x is
{:?}
"
, x);
}