Python a fast way to count match in a list
<pre><code>print sum(1 for x in alist if x[1] == 8)
</code></pre>

<p>This code runs fine, but it is so slow. Is there a way better than this. Because, my list is very large and the computation takes a lot of time. Do you know a better and faster way to do it?</p>
