in reply to extracting columns
i would read the file into an array its cleaner and easier to read
#!/usr/bin/perl my $file="file.txt"; open (FH, "< $file") or die "$!"; while (<FH>) { push (@lines, $_); } close FH or die "$!"; print "@lines[0]\t@lines[1]\n\n";
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: extracting columns
by GrandFather (Saint) on Mar 22, 2012 at 20:46 UTC |