Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
First solution in Creative category for Just Fizz! by CUMTB_WSR
def checkio(num: int) -> str:
# your code here
return str(num)*(int(num%3)!=0)+"Fizz"*(int(num%3==0))
print("Example:")
print(checkio(3))
# These "asserts" are used for self-checking
assert checkio(15) == "Fizz"
assert checkio(6) == "Fizz"
assert checkio(10) == "10"
assert checkio(7) == "7"
print("The mission is done! Click 'Check Solution' to earn rewards!")
Oct. 27, 2024