Week 3's assignment for Functional Programming Scala @ Coursera.