my implementation of 99 problems in scala