Add alt code: since I'm a lost :-) vim user and the author provided how to add back support for arrow keys I made this in the alt version. Updated .gitignore for this. Format fix README.md. Fix link. Added link to Yusuke Endoh's analysis of the entry as he offers some fun commentary and especially fun is how to cheat. Perhaps I should not do that but since he provided some other fun comments and since the README.md files are no longer supposed to have spoilers as such why not.
90 lines
3.6 KiB
C
90 lines
3.6 KiB
C
#include <ncurses.h>
|
|
|
|
#define T typedef unsigned
|
|
T long G;
|
|
T short CT;
|
|
#define ATG srand(time(0)); initscr(); cbreak(); noecho(); start_color(); keypad(stdscr,1);
|
|
#define GG(T,C) attrset(A_BOLD*!(T)|COLOR_PAIR(C%2+1));
|
|
#define AC(G) init_pair(G/2,G,nodelay(stdscr,G/3));
|
|
#define TCT(A,G,C) mvaddch(A+CTT*6+4,CGA*12+G,C)
|
|
#define AGG A&2?KEY_UP:KEY_DOWN:A&1?KEY_RIGHT:KEY_LEFT
|
|
#define CAT mvprintw(2,40,"%d",TC)
|
|
#define GAT int main()
|
|
#define AAA refresh()
|
|
#define TAG endwin()
|
|
#define GCA clear()
|
|
#define TCA clock()
|
|
#define CCC rand()
|
|
#define CC getch()
|
|
#define GA return
|
|
#define T(T) #T#T#T#T#T#T T
|
|
#define G(G) while(G)
|
|
#define A(A) A { A }
|
|
|
|
G AA[1<<16]; G GT[1<<16];
|
|
G CAA, CA, CTG, TA, CG, CTT, CGA, TC, T, GTC;
|
|
char *ACG="HXXTP02^OCBHL\\XP``T^NDP800SQSW\\X@@@0c13RZLLH<WWWWWWWW |