Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?
 
PerlMonks  

Re^2: Regex refresher

by xicheng (Sexton)
on Mar 22, 2007 at 16:20 UTC ( [id://606069]=note: print w/replies, xml ) Need Help??


in reply to Re: Regex refresher
in thread Regex refresher

Another way to do this(since you are asking for a regex solution)

$line =~ s/(\s+)/my $n++ < 6 ? ',': $1/eg;

not very efficient though..

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others studying the Monastery: (4)
As of 2024-04-25 07:06 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found