Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw

Re: Code Review on Several Interesting Points

by CharlesClarkson (Curate)
on Nov 12, 2001 at 10:07 UTC ( #124758=note: print w/ replies, xml ) Need Help??

in reply to Code Review on Several Interesting Points

It bugs me that $/ is global.

You could avoid $/ by using read which, I believe, is more efficient.

sub scanfile ($) { my $filename = shift; open my $handle, '<', $filename or croak "$filename: $!"; read $handle, my $buffer, -s $handle; return scan ($buffer); }

Charles K. Clarkson

And he puzzled three hours, till his puzzler was sore. Then the Grinch thought of something he hadn't before!
- Dr. Seuss

Comment on Re: Code Review on Several Interesting Points
Select or Download Code

Log In?

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

How do I use this? | Other CB clients
Other Users?
Others contemplating the Monastery: (4)
As of 2015-11-29 05:17 GMT
Find Nodes?
    Voting Booth?

    What would be the most significant thing to happen if a rope (or wire) tied the Earth and the Moon together?

    Results (747 votes), past polls