Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"
 
PerlMonks  

Re: RegEx related line split

by Lotus1 (Chaplain)
on Nov 11, 2011 at 21:58 UTC ( #937675=note: print w/ replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    my $RefLine = "(a) This is first line. (b) This is second line; (c) Th
    +is is different line 32. (d) Here is the last line.";
    
    @lines = $RefLine =~ /(\([a-z]\).*?)(?=$|\([a-z]\))/g;
    print ">>$_<<\n" foreach @lines;
    

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others romping around the Monastery: (5)
As of 2015-05-25 16:32 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    In my home, the TV remote control is ...









    Results (487 votes), past polls