Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re: Counting number of characters in a string

by OeufMayo (Curate)
on Mar 13, 2001 at 02:40 UTC ( #64000=note: print w/ replies, xml ) Need Help??


in reply to Counting number of characters in a string

Yet Another (stupid) Way To Do It:

$string = "foobar"; $count = $string =~ s/(.)/$1/sg;
<kbd>--
my $OeufMayo = new PerlMonger::Paris({http => 'paris.mongueurs.net'});</kbd>


Comment on Re: Counting number of characters in a string
Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://64000]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others pondering the Monastery: (8)
As of 2014-07-31 08:15 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite superfluous repetitious redundant duplicative phrase is:









    Results (246 votes), past polls