n = gets.to_i for i in "a".length .. n three = "abc".length five = "fiver".length a = i % three == 0 b = i % five == 0 if a && b puts "FizzBuzz" elsif a puts "Fizz" elsif b puts "Buzz" else puts i end end