title: deleting a 2D array of ints, set pointer to null in C
body: <p>For an upcoming midterm, one of our practice problems was to write a function that will delete a 2D array of ints and set the pointer to NULL. I thought I knew how to do this but some other people in the class said some stuff that really confused me (they said we should use triple pointers so that we can modify the array, but isn't an array basically a pointer in itself? so wouldn't a **array be equivalent to a triple pointer?). Is my function correct?</p>
  
  <pre><code>void cleanUp(int** array, int numRows, int numCols) {
    for (int i = 0; i &lt; numRows; ++i) {
      free((*array)[i]);
    }
    free(*array);
    *array = NULL;
  }
  </code></pre>