[Date Prev][Date Next][Thread Prev][Thread Next] [Search] [Date Index] [Thread Index]

Re: [FWP] Wanted - Have = Need



Ronald J Kimball <rjk@linguist.dartmouth.edu> wrote:

>  perl -e '@w{<>}=();@ARGV=HAVE;delete@w{<>};print%w' WANT

One stroke less, but less forgiving of incorrect files:

   perl -e "$w{$_}++for<>;print+grep$w{$_}&1,%w" WANT HAVE

-- 
Keith C. Ivey <kcivey@cpcug.org>
Washington, DC

==== Want to unsubscribe from Fun With Perl?  Well, if you insist...
==== Send email to <fwp-request@technofile.org> with message _body_
====   unsubscribe