moved Main.scala to simplify things