for mut i in 0..448 {
i += 179;
println!("{}", i)
How can I add all of the values that get printed to the terminal when this is ran?
for mut i in 0..448 {
i += 179;
println!("{}", i)
How can I add all of the values that get printed to the terminal when this is ran?
fn main() {
let a = 179..627;
let sum: i32 = a.into_iter().sum();
println!("the total sum is: {}", sum);
this worked