You're almost there. Suppose the question was "find a solution of what to order to get 'n' McNuggets"? You have the core of that, and could solve that question with something like:
solution = (0,0,0)
for a in range(0,n):
for b in range(0,n):
for c in range(0,n):
if 6*a + 9*b + 20*c == n:
solution = (a,b,c)
Now, all you need to do is surround this with bookkeeping like you have:
while consecutivecount < 6:
solution = (0,0,0)
# ** find a solution like above
if solution == (0,0,0):
consecutivecount = 0 #resets consecutivecount value to zero
savedn += [n] #adds current value of n to list
else:
consecutivecount += 1
n += 1 #increases value of n to continue test loop
So you look for a solution for n
and if you found one, you count up the consecutivecount, and if you didn't find one, you save off another unattainable number (and reset consecutivecount). In either case, time to go on to another n
.