I'm trying to create a multidimensional array (temp) that has dimensions of inRows x inColums but i get errors of "Expected constant expression" and "Cannot declare array of constant size 0".
void createIntArray(int inRows, int inColumns){
int temp[inRows][inColumns];
}
I tried setting inRows and inColumns to be constant as follows but to no avail. Please give me a hand creating the temp array.
void createIntArray(int inRows, int inColumns){
const int r(inRows), c(inColumns);
int temp[r][c];
}
Thanks
void createIntArray(int inRows, int inColumns){
int temp[inRows][inColumns];
}
I tried setting inRows and inColumns to be constant as follows but to no avail. Please give me a hand creating the temp array.
void createIntArray(int inRows, int inColumns){
const int r(inRows), c(inColumns);
int temp[r][c];
}
Thanks