getch() legge UN CARATTERE.

Dando come input 77[INVIO] tu gli stai dando due (tre) caratteri: 7 7 e \n (ma su quest'ultimo non sono sicuro al 100%)