Share
USING LOOPS IN PYTHON
Question
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Q2. Write a program to print all the values between 0 to 20 that aren’t divisible by 3 or 5 using continue .
Answers ( 2 )
Ans.
for x in range(21):
if (x % 3 == 0 or x % 5 == 0):
continue
print(x)
for i in range(0,21):
if i%3==0 or i%5==0 :
continue
print(i)