in reply to Re^3: Sort then conditionally sort
in thread Sort then conditionally sort

I was wondering how to get the <DATA> to be read in to this code. I wasnt familiar with this method. So you are saying that I can read the 2 col file line by line, with the code as is? So to invoke this code - do I do something like this> Let's say this code is saved as sort_it.pl
Then from a cmd line I would type
c:> perl sort_it.pl myinputfile.txt

Is this close?
thank you in advance...
Im really trying to follow this stuff.

Replies are listed 'Best First'.
Re^5: Sort then conditionally sort
by ikegami (Patriarch) on Apr 15, 2009 at 02:31 UTC
    By passing the file name like that, the contents of that file will be available with <>, which is short for <ARGV>. See perlvar for ARGV.