all numbers which are multiple of 17,
but not the multiple 5, between 2000
2500 ?
Answers
Answered by
1
Answer:
Neha q itna dukh jhel rahe ho type karne ka
Answered by
1
Answer:
# WAP to Find all numbers which are multiple of 17,
# but not the multiple of 5, between 2000 and 2500?
for i in range(2000, 2500):
if (i % 17 == 0) and (i % 5 != 0):
print(" ", i)
Output:
2006
2023
2057
2074
2091
2108
2142
2159
2176
2193
2227
2244
2261
2278
2312
2329
2346
2363
2397
2414
2431
2448
2482
2499
Explanation:
# Using for loop and given the range 2000 to 2500
for i in range(2000, 2500):
# Using if Statement to control the condition
# first for Multiple of 17
# second for not Multiple of 5
if (i % 17 == 0) and (i % 5 != 0):
# Print the Values using print
print(" ", i)
Similar questions