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

ranged conditional with variable

by Anonymous Monk
on Aug 22, 2006 at 00:01 UTC ( [id://568722]=perlquestion: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    foreach my $line (<FILE>) {
        if ($line =~ /PatternBegin/ .. /PatternEnd/) {
            $str .= $line;
        }
    }
    
  2. or download this
    foreach (<FILE>) {
        if (/PatternBegin/ .. /PatternEnd/) {
            $str .= $_;
        }
    }
    

Log In?
Username:
Password:

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

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

    No recent polls found