Updated done and undone to handle wrong user inputs
Updated done and undone to handle wrong user inputs