I am doing program in c. I wanted to scan my input like :
[root@localhost sudoers.d]# cd /home/Hitesh/
Display all 113 possibilities? (y or n)
Here in bash,when user enters 'n' or 'y' it directly come on prompt.
But in c program if I am taking input through getchar() and then if I press 'n' or 'y',I explicitly have to press enter key after that to resume execution.
So I want,my execution resume as soon I press 'n',it should not wait for enter key press.
How can I achieve this in c programming.