Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

Re: print a hash ref

by johngg (Abbot)
on Jul 09, 2013 at 16:53 UTC ( #1043354=note: print w/replies, xml ) Need Help??


in reply to print a hash ref

next if $. == 35 or $. == 36;

Did you know that you can use the flip-flop with line numbers?

$ perl -Mstrict -Mwarnings -E ' open my $inFH, q{<}, \ <<EOD or die $!; Line 1 Line 2 Line 3 Line 4 Line 5 Line 6 Line 7 EOD while ( <$inFH> ) { next if 3 .. 5; print; }' Line 1 Line 2 Line 6 Line 7 $

Just another bit of Perl shorthand :-)

Cheers,

JohnGG

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others contemplating the Monastery: (4)
As of 2016-09-25 07:24 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Extraterrestrials haven't visited the Earth yet because:







    Results (465 votes). Check out past polls.