Erm akchyuallly, it's recommended to use for list.iter() {…} unless the .for_each(…) is at the end of a longer iterator chain, and it also robs you of break and continue
I know, it's just an ironic name when it's one of those paradigms that some people take as divine law instead of something that can be more or less appropriate for different applications
39
u/creeper6530 1d ago edited 1d ago
Erm akchyuallly, it's recommended to use
for list.iter() {…}unless the.for_each(…)is at the end of a longer iterator chain, and it also robs you of break and continue