Implemented homework for Scala day 1