Hi guys...as you can see I have a lot of questions about C...
Today I was changing my functions and I got complains from the compiler. This is the question: I have a function that takes one argument, a pointer, i.e.
Code:
void foo(double *wof)
Now I want to use foo in main
Code:
int main()
{
      double array[10];
      foo(&array);
}
my compiler says " warning: passing argument 1 of ‘foo' from incompatible pointer type", but the program is working. I cannot understand why because, as far as I know, passing &array means that I am pointing at the first place of array, i.e. array[0].