I tried to do the FizzBuzz without double if of same thing
def fizz_buzz(input):
"""Fizz Buzz"""
answer = "Fizz" if input % 3 == 0 else ""
answer += "Buzz" if input % 5 == 0 else ""
answer = input if len(answer) == 0 else answer
return answer
print(fizz_buzz(2))
print(fizz_buzz(3))
print(fizz_buzz(5))
print(fizz_buzz(6))
print(fizz_buzz(10))
print(fizz_buzz(15))
print(fizz_buzz(16))
Not sure if it would be considered “Ugly” as Mosh likes to put it.