I'm trying to use getchar() to retrieve 1 keystroke at a time from the keyboard. Though it does this, the problem I'm having is doesn't send it immediately, it waits for the enter key to be pressed and then it reads 1 char at a time from the buffer.
int main(){
char c = getchar();
putchar(c);
return 0;
}
How do I immediately read each keystroke as it's pressed from the keyboard? Thanks