+ 1

How do I implement “continue” to skip the even numbers in the output..Please🙏

n = int(input()) for x in range(1, n): if x % 3 == 0 and x % 5 == 0: print("FreezeBreath") elif x % 3 == 0: print("Freeze") elif x == 6: continue elif x % 5 == 0: print("Breath") else: print(x)

11th Dec 2021, 4:53 PM
LEYE🧘🏾‍♂️
LEYE🧘🏾‍♂️ - avatar
2 Antworten
+ 2
Just add this condition elif x % 2 == 0 : continue
11th Dec 2021, 4:56 PM
Pariket Thakur
Pariket Thakur - avatar
+ 3
12th Dec 2021, 11:52 AM
Lothar
Lothar - avatar