def allDigiEven(number): return all(int(i)%2==0 for i in str(number)) def pt(a,b): ans=[i for i in range(a,b+1) if allDigiEven(i)] print(ans) pt(100,400)
Standard input is empty
[200, 202, 204, 206, 208, 220, 222, 224, 226, 228, 240, 242, 244, 246, 248, 260, 262, 264, 266, 268, 280, 282, 284, 286, 288, 400]