Changed void back to int in main