Minor code cleanup, added third Scala variation of editDistance