in reply to regexp to match repeated charater

Here is one way to do it...
#!/usr/bin/perl my $string = 'It was an intelligent stori'; my $matches = 0; my (@chr) = split(//, $string); foreach (@chr) { $matches++ if ($_ =~ m/[iI]/); # match it & count } print "Content-type: text/html\n\n"; print "<html>String: $string<hr>Matches: $matches</html>\n";
Good Luck ^^