Simple functions for printing Fizz, Buzz, or FizzBuzz
Python
Switch branches/tags
Nothing to show
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
FizzBuzz.py
README.md

README.md

fizzbuzz

Program prints numbers 1 to 100. For multiples of three, program prints "Fizz" instead of the number and for multiples of five, it prints "Buzz". For numbers which are multiples of both three and five, program prints "FizzBuzz".

There are numerous ways to implement this algorithm. Here are four ways, each of varying complexity and style.