#include <ncurses.h>

int main(void){
  initscr();
  nodelay(stdscr, TRUE);

  while(1)
  {
    printw("B");
    refresh();
    if(getch() == 'A'){ break; }
    sleep(1);
  }
  endwin();
  return 0;
}