• what is wrong?

Question related to mission The Stones

 
    def stones(pile,moves):
results=[False]+[True]*pile
for count in range(1,pile+1):
    possible=[x for x in moves if count-x>=0]
    results[count]= not(all(results[count-i] for i in possible))
if results[pile]:                                                                                   
    return 2
else:
    return 1

why does it not work?