sarf13 has asked for the wisdom of the Perl Monks concerning the following question:

Hi All

how can i write a map reduce streaming program in perl. i had gone through the documentation of hadoop.the map reduce coding is possible in python. defiantly there will be a way perl also.can any one give me some example code regarding this

Thanks all

Replies are listed 'Best First'.
Re: hadoop mapreduce coding in perl
by AnomalousMonk (Archbishop) on May 26, 2012 at 19:00 UTC

    See List::Util::reduce().

    >perl -wMstrict -le "use List::Util qw(reduce); ;; use vars qw($a $b); my $sum = reduce { $a + $b } 1 .. 100; print $sum; " 5050
Re: hadoop mapreduce coding in perl
by sauoq (Abbot) on May 26, 2012 at 19:22 UTC

      Hi thanks for your reply.i am new in hadoop.can you give me some example script for streaming.i had gone thorugh wordcount mapreduce script come with hadoop package. but i want to write a mapreduce script for data comparision of two diffrent file. can you suggest the possible way.

      thanks