What is the equivalent to getch() & getche() in Linux?

后端 未结 6 1979
南方客
南方客 2020-11-22 05:53

I am not able to find the equivalent header file for conio.h in Linux.

Is there any option for getch() & getche() function in Linux?

6条回答
  •  醉话见心
    2020-11-22 06:30

    As said above getch() is in the ncurses library. ncurses has to be initialized, see i.e. getchar() returns the same value (27) for up and down arrow keys for this

提交回复
热议问题