Python's string count function doesn't use regex
<p>when trying to count all letters in a string using the count function and the regex [A-Za-z], it returns a a value of zero.</p>

<p>For instance:</p>

<pre><code>string="Hi, everybody. Let's dance!"

string.count('[A-Za-z]') ## prints 0
</code></pre>

<p>any suggestions?</p>

<p>Use regular expressions:</p>

<pre><code>len(re.findall('[A-Za-z]', string))
</code></pre>

python regex python-2.7 function