Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re^2: simple regex question

by phenom (Chaplain)
on Dec 01, 2010 at 00:09 UTC ( #874591=note: print w/ replies, xml ) Need Help??


in reply to Re: simple regex question
in thread simple regex question

pipeops, glad to hear you have it working. But for future reference, please wrap your <code> in tags - it's MUCH easier to read:

foreach $line (@exceptions) { if ( $line =~ m/^n/ ) { $line =~ s/^n//s; push( @before, $line ); } elsif ( $line =~ m/^i/ ) { $line =~ s/^i//s; push( @implementation, $line ); } elsif ( $line =~ m/^b/ ) { $line =~ s/^b//s; push( @backup, $line ); } elsif ( $line =~ m/^o/ ) { $line =~ s/^o//s; push( @offline, $line ); } }


Comment on Re^2: simple regex question
Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others wandering the Monastery: (15)
As of 2015-07-30 14:30 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (271 votes), past polls