Posts

Showing posts from November, 2015

Exploring cellular automata with conway's game of life as a foundation

//////////////////////////////////////////////////////////////////////////////// // THE SCOTCH-WARE LICENSE (Revision 0): // <aaronryool/gmail.com> wrote this file. As long as you retain this notice you // can do whatever you want with this stuff. If we meet some day, and you think // this stuff is worth it, you can buy me a shot of scotch in return //////////////////////////////////////////////////////////////////////////////// # include < stdlib.h > # include < stdio.h > # include < string.h > # include < unistd.h > # include < signal.h > typedef enum { false , true } bool ; # define BGBLACK " \033 [40m " # define BGRED " \033 [41m " # define BGWHITE " \033 [47m " # define RESET " \033 [0m " # define CLEAR " \033 [2J " # define HIDE_CURSOR " \e [?25l " # define SHOW_CURSOR " \e [?25h " # define SIZE ( width * height ) # define CURSOR ( x ,