This is an example of Aggregated Hadoop Map/Reduce application. It reads the text input files, breaks each line into words and counts them. The output is a locally sorted list of words and the count of how often they occurred.
bin/hadoop jar hadoop-examples-*.jar aggregatewordcount <in-dir> <out-dir> numOfReducers textinputformat
1,The Nightmare Before Christmas,1993,3.9,4568
3,Orphans of the Storm,1921,3.2,9062
4,The Object of Beauty,1991,2.8,6150
6,One Magic Christmas,1985,3.8,5333
9,Nosferatu: Original Version,1929,3.5,5651
10,Nick of Time,1995,3.4,5333