20 lines
370 B
Python
20 lines
370 B
Python
into = input()
|
|
x, y, n = into.split(' ')
|
|
|
|
for i in range(1,int(n)+1):
|
|
fizz = False
|
|
buzz = False
|
|
if i%int(x)==0 :
|
|
fizz = True
|
|
if i%int(y)==0 :
|
|
buzz = True
|
|
|
|
if fizz and buzz :
|
|
print('FizzBuzz')
|
|
elif fizz and not buzz :
|
|
print('Fizz')
|
|
elif buzz and not fizz :
|
|
print('Buzz')
|
|
else :
|
|
print(i)
|