WAP to enter all the even numbers between 2 to 50 in a list called evenList.in python
Answers
Answered by
1
evenList = [2]
for i in range(2,51,2):
evenList.append(i)
print(evenList)
for i in range(2,51,2):
evenList.append(i)
print(evenList)
Answered by
0
Answer:
evenList = [ ]
for i in range(1, 51):
if i%2 == 0:
evenList.append(i)
print(evenList)
Similar questions