I was told to solve a problem in which I would have to find out the number of 4-digit numbers which are all composed of odd digits. I tried the following python code:
I believe something like this would work if you're looking to model what you already have, but I echo the comment by yotommy that some intuitive multiplication would do the trick.
for a in range(1111,10000):
allOdd = True
for b in str(a):
if int(b) % 2 == 0:
allOdd = False
if(allOdd):
new_list.append(a)