I've got a problem. I am trying to free an array of pointers using a loop, but it does not work. Could somebody help me with that?
This is the allocation code:
void create1(A*** a, int size)
{
*a = (A**) malloc(size* sizeof(A*));
for (int i = 0; i < size; i++)
{
a[0][i] = (A*)malloc(size * sizeof(A));
}
}