num_range=int(input("enter range upto which you want to find even numbers : "))
for i in range(1,num_range):
if i%2==0:
print(i,end=’ ')
2 Likes
Correct. Keep it up.
1 Like
Good and also you can take starting value of range as input so that user can decide his start and end of range.
1 Like