Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?
 
PerlMonks  

Re: Printing first and last line

by pvaldes (Chaplain)
on Aug 14, 2012 at 08:27 UTC ( #987294=note: print w/ replies, xml ) Need Help??


in reply to Printing first and last line

perl -ne 'print if eof || $. == 1' my_file


Comment on Re: Printing first and last line
Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others scrutinizing the Monastery: (5)
As of 2014-12-22 06:27 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    Is guessing a good strategy for surviving in the IT business?





    Results (111 votes), past polls