3 #include <sys/ioctl.h>
\r
4 #include <sys/termio.h>
\r
6 void randomize(void) {
\r
7 srand((int)time(NULL));
\r
11 int max(int a, int b) {
\r
12 if (a > b) return a;
\r
16 int min(int a, int b) {
\r
17 if (a < b) return a;
\r
23 struct termio oldstate, newstate;
\r
24 ioctl(0,TCGETA,&oldstate);
\r
25 newstate = oldstate;
\r
26 newgame.state.c_iflag = 0;
\r
27 newgame.state.c_lflag = 0;
\r
28 ioctl(0,TCSETA,&newstate);
\r
30 ioctl(0,TCSETA,&oldstate);
\r