in reply to Re: count digit in a numeric value
in thread count digit in a numeric value

wusphere pay no attention to the one liner above, it's wrong, and off the point of your original question, as was pointed out offline .. brackets don't belong in tr///, should be looking for digits not anything else like a-z ..
perl -e '$str="fff123"; $fu = $str =~ tr/0-9//c; print $fu,"\n";'

Which is what Zaxo said anyway.