I wrote a code on windows, using the function getch() from stdio. The thing is I have to use an input function that does not require pressing enter.
getch()
stdio
We don't do miracles in Linux. You either use other things besides stdio.h, or go without any equivalent of getch and do depend on Enter being pressed.
stdio.h
getch