Update main.c

now consumes unwanted input after input handling