puoi usare un system("pause>nul");
oppure un while(getchar()!='\n');