There's a very pretty way to count them with the tr// operator, my $vowel_count = tr/AEIOUYaeiouy//; If you want the character list in a variable, you need to string-eval: my $foo_count = eval "tr/$foo//";
After Compline,
Zaxo
In reply to Re: count subset of chars in a line
by Zaxo
in thread count subset of chars in a line
by GrandFather
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |