simple game of life program in C++