c++ two dimensional array definition - Stack Overflow
int ** data is a pointer to a pointer to an int. Passing data to sums first argument is actually just passing a int* to it, which is not identical to int **. Further, once you're in sum(), it has no idea that int **data points to a 2 dimensional array, it...