What have I done wrong? The error I'm receiving is saying that I can't use bWidth and bHeight to set the size of the array unless they're constant, but I very much need them to be variable. Have I formatted this poorly?
int random_state(int bWidth, int bHeight) {
int board_state[bWidth][bHeight];
for (int i = 0; i <= bWidth * bHeight; i++) {
srand(time(NULL));
int randomOut = rand() % 2 - 1;
board_state[i][i] = randomOut;
cout << board_state[i][i];
}
cout << "Test";