All Questions
1 question
0
votes
2
answers
66
views
2D array of given size
I want to create a 2D array of ints, where the array's dimension is given at run time (not compile time). So far, I have been using:
int **ptr = malloc(m * sizeof(int*));
for (size_t i = 0; i < m;...