Search across blog, articles, projects, courses, and community posts
Read an integer n. For each number from 1 to n (inclusive), print one line:
Fizz if it is divisible by 3Buzz if it is divisible by 5FizzBuzz if divisible by bothExample
Input: 5
Output:
1
2
Fizz
4
Buzz
1 <= n <= 10000
5
1 2 Fizz 4 Buzz