Hello,
Consider following code:
What's wrong with this? I've tried same code in C, it works except that complier throws warning about incompatible pointers, while in C++ it's an error - any ideas?Code:void foo(int **arr);
int main()
{
int array[10][10];
int **ptr;
ptr = array; // error here
foo(array); // here aswell
printf("%d", array);
getchar();
return 0;
}
void foo(int **arr)
{
printf("Hello\n");
}