Sorry if this shouldn't be a new thread, but rather an addition to an old one. I see a lot of Count threads, but I didn't see any relating to the instruction to make lists countable. My code runs fine. and I pass the level, but I tried inserting the balls list and the code ignores these numbers in counting. Any idea how to make the code look at the contents of the list?
Thanks for the help.
def count(sequence, item): counter = 0 for x in sequence: if item == x: counter += 1 print counter return counter balls = [3,4,3] count([1,2,3, balls,3,2,3], 3)