Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options
 
PerlMonks  

Re: read a file twice...

by clintp (Curate)
on Apr 15, 2002 at 15:56 UTC ( #159245=note: print w/replies, xml ) Need Help??


in reply to read a file twice...

In the spirit of TIMTOWDI and filed under "don't do this at home":
#!/usr/bin/perl -w push(@ARGV, "filetoread", "filetoread"); while(<>) { print; } continue { # This block not necessary, but for fun only print "Second verse, same as the first!\n" if (eof ARGV && @ARGV); }

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://159245]
help
Chatterbox?
[LanX]: like shmem commands : shmctl, shmget, shmread, shmwrite...

How do I use this? | Other CB clients
Other Users?
Others browsing the Monastery: (7)
As of 2017-06-23 19:06 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    How many monitors do you use while coding?















    Results (554 votes). Check out past polls.