in reply to Is this code logical?

Your code seems to be the equivalent of this code:
{ my %seen; local($^I, @ARGV) = ("", $outputfile); while (<>) { next if $seen{$_}++; print; } }
It's a good thing to learn about in-place editing mode.

-- Randal L. Schwartz, Perl hacker
Be sure to read my standard disclaimer if this is a reply.

Replies are listed 'Best First'.
Re^2: Is this code logical?
by blazar (Canon) on Feb 25, 2006 at 09:14 UTC
    This is very good advice, in principle, especially for the benefit of other readers, but for the OP evidence is that won't listen in any case. Indeed I'm afraid to have to do an ad hominem attack -and I shamelessly admit I'm doing one!-, but I doubt he's really willing to learn, let alone to listen. Which makes one wonder why he keeps asking, instead! Mistery...