fn main(){ let input = scan(); let n: usize = input.parse().unwrap(); fizzbuzz(n); } fn fizzbuzz(n: usize) { for i in 1..n + 1 { if i % 3 == 0 { print!("Fizz"); } if i % 5 == 0 { print!("Buzz"); } if i % 3 == 0 || i % 5 == 0 { println!(""); continue; } println!("{}", i); } } fn scan() -> String { let mut s = String::new(); std::io::stdin().read_line(&mut s).unwrap(); s.trim().to_string() }