Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

(jeffa) 2Re: Matching over multiple lines in a scalar

by jeffa (Bishop)
on Oct 27, 2002 at 23:54 UTC ( #208411=note: print w/replies, xml ) Need Help??


in reply to Re: Matching over multiple lines in a scalar
in thread Matching over multiple lines in a scalar

my $info; { local $/ = undef; $info = <DATA>; }
can be golfed reduced down to:
my $info = do {local $/;<DATA>};
UPDATE:
Well shucks ... chromatic has already said that in this thread (and thanks for the doobie doobie do, Aristotle).

jeffa

L-LL-L--L-LL-L--L-LL-L--
-R--R-RR-R--R-RR-R--R-RR
B--B--B--B--B--B--B--B--
H---H---H---H---H---H---
(the triplet paradiddle with high-hat)

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (7)
As of 2021-05-08 11:24 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Perl 7 will be out ...





    Results (96 votes). Check out past polls.

    Notices?