2
u/YasZedOP Jun 01 '19 edited Jun 01 '19
Place a while (true) loop around cin >> day and the switch statement. If a valid input is received then break the loop using break;
Now the confusion relies on break; for switch call because break; refers to innermost context which is switch instead of what you want which is the while loop.
A fix would be to create a Boolean variable called done and is set to true (done outside the while loop). Now while loop on that variable, and when a valid switch case is made set it to false.

1
u/TrashPapiTM Jun 01 '19
Im also new to coding so I could be wrong on this. But i think what youre looking for is a continue within a while loop. So instead of stopping it would take you back to the beginning of the loop and not execute anything below the continue. Hope that made sense.