Exercism.io solutions in Scala