Fixed error in main method #2