Baseline solution + gen + test.
Added a functional MapReduce implementation.