Game of life help
//Life Project
#include <iostream>
#include <stdlib.h>
#include <cmath>
#include <cstdlib>
using namespace std;
int x, y, spots;
int life_spots [22][80];
void end();
void fill();
const int N = 21;
const int O = 79;
string answer;
int s, r, n, o;
int
main ()
{
life_spots[s][r] = 0;
for (s = 0; s < 80; s++ )
{
for (r = 0; r < 22; r++ )
{
}
}
fill ();
}
void fill ()
{
cout << "How many spots in the 22X80 Graph would you to populate?";
cin >> spots;
for (n=0; n < spots; n++)
{
cout << "Please enter the X coordinate followed by the Y Coordinate,";
cout << "\n";
cout << "with a space in between the two values:";
cin >> x >> y;
if (y > 80)
{
cout << "Error, number must be less than or equal to 80 for Y\n";
break;
}
if (x > 22)
{
cout << "Error, number must be less than or equal to 22 for X\n";
break;
}
}
system("pause");
end();
}
void
end()
{
cout << "Would you like to start over?\n";
cin >> answer;
if (answer == "yes")
{
main();
}
}

