Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

Re: Re: what's this loo code? (*slurp*)

by Kanji (Parson)
on Feb 04, 2003 at 18:51 UTC ( #232619=note: print w/ replies, xml ) Need Help??


in reply to Re: what's this loo code? (*slurp*)
in thread what's this loo code?

I'm almost certain you can make that faster or shorter

I can't imagine it making a significant dent in speed for small(er) files, but -l (sh|c)ould be omitted.

Perhaps...

perl -ne 'END{ print $., $/ }' file

...or...

perl -ne 'END{ print $. }' file

    --k.



Comment on Re: Re: what's this loo code? (*slurp*)
Select or Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others contemplating the Monastery: (6)
As of 2014-08-30 22:05 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The best computer themed movie is:











    Results (294 votes), past polls