open OUT,'|program' or die $!; open IN,'file.txt' or die $!; #if you don't need to process each line...I don't see why not printing + all the lines at once like: print OUT <IN>; #but if you must print one line at a time: while(<IN>){ #do whatever you want with the line. print OUT $_; } close OUT; close IN;
In reply to Re: (redmist) Re: Reading a file
by Ido
in thread Reading a file
by ep
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |