Feed on
Posts
Comments

an example of how to read in the contents of a file and then write them out, in perl

open(INPUT,$ARGV[0]);
open(OUTPUT,”>$ARGV[0].out”);

while (<INPUT>) {
print OUTPUT $_;
}

close(INPUT);
close(OUTPUT);


Bookmark and Share

if that was helpful ...

check out the other tips and tricks i've compiled on these pages. you might learn something else interesting!

Did I get this wrong? Let me know!

Trackback URI | Comments RSS

More blogs about http://desk.stinkpot.org:8080/tricks.