Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re^2: hawk@rthawk.com

by Anonymous Monk
on Feb 02, 2005 at 01:58 UTC ( #427115=note: print w/ replies, xml ) Need Help??


in reply to Re: hawk@rthawk.com
in thread numbers

What do you mean "Right answer"? There are many ways of doing things in perl. You don't have get snotty about it. Here is yet another way that is even more efficent then your "right answer", but not as efficent as my previous example:

&commify($x);#Robust - Does all size numbers sub commify { local $_ = shift; 1 while s/(-?\d+)(\d{3})/$1,$2/; return $_; }


Comment on Re^2: hawk@rthawk.com
Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others about the Monastery: (9)
As of 2014-11-28 07:09 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My preferred Perl binaries come from:














    Results (193 votes), past polls