Using for/if to keep count in python
<p>I'm attempting to create a function that finds how many times an item occurs in a function. I have the code below, but it ends up counting all the items in the list(6), not just the one i want( in this case 1). I know i'm not returning anything, the print is mainly for me to see what answer I get.</p>

<pre><code>def count(sequence, item):
    found = 0
    for i in sequence:
        if item in sequence:
            found = found + 1
    print found

count([1,2,1,2,4,5], 1)
</code></pre>