+ Added a while loop to wait for the user input.