Changed location of main method and some other stuff