Added a main menu and userinput loop