import sys my_list=[] for i in range(0,50): my_list.append(i+1) for i in my_list: if i % 5 == 0: print(i)