Example: Count Word Occurrences
map(String input_key, String input_value):
for each word w in input_value:
EmitIntermediate(w,"1");
reduce(String output_key, Iterator intermediate_values):
in result = 0;
for each v in intermediate_values:
result+= ParseInt(v)
Emit(AsString(result))
José M. Vidal
.
20 of 24