Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <ncurses.h>
- int main()
- {
- int n;
- initscr();
- cbreak();
- noecho();
- scrollok(stdscr, 1);
- nodelay(stdscr, 1);
- while (true)
- {
- if ((n = getch()) != -1)
- {
- printw("You pressed %d\n", n);
- }
- napms(500);
- printw("Running\n");
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement