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

newline behavior in Regular Expression

by asinghvi (Acolyte)
on Apr 12, 2004 at 18:45 UTC ( #344473=perlquestion: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    $PAT = '$X =~ s{^(.*?)Resolved (\d+) problems out of (\d+) picked(.*?)
    +$}{ (($3-$2)/$3>.5) ? 1 : 0 }se';
    
  2. or download this
    $X = "Line1\nLine2Resolved 200 problems out of 5000 picked\nLine4\nLin
    +e5";
    

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://344473]
Approved by herveus
Front-paged by diotalevi
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others browsing the Monastery: (6)
As of 2021-10-26 16:15 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    My first memorable Perl project was:







    Results (90 votes). Check out past polls.

    Notices?