Added a main method at the bottom.