Creating a crossword puzzle generator. The grid size is chosen by input and the grid will be generated. I'd like the grid to be an object with rows and columns but also a 2d array which will allow me to divide the grid into smaller sections for randomising between blank and numbered squares. I am not sure where to implement it. It has to be a 2d array as I will do dividing and inverting the layout.
Here is my Grid class with some methods. (And the rest)
class Grid
{
int rows; //x
int columns; //y
Square field;
public:
void SetXY(int x, int y)
{
rows = x;
columns = y;
return;
}
public:
void DisplaySize()
{
cout << "Rows = ", rows, "Columns = ", columns;
}
};