Passing arrays to functions(Simple question)!
-
Hi, hope someone can help me out here! Is it possible to pass an array to a function? I have a
double data[32768]
and I want to process it in some other function but I'm not sure of the syntax used to pass the array to another function. I trieddouble[] void Window(double data[]) { return data[]; }
but obviously that didn't work! Thanks in advance, Paddy -
Hi, hope someone can help me out here! Is it possible to pass an array to a function? I have a
double data[32768]
and I want to process it in some other function but I'm not sure of the syntax used to pass the array to another function. I trieddouble[] void Window(double data[]) { return data[]; }
but obviously that didn't work! Thanks in advance, PaddyPaddy wrote: double[] void Window(double data[]) Did you compiler swallow this? :wtf: You should be doing something like this (if I get your point):
double *Window(double *data, size_t count)
{
return data;
} -
Paddy wrote: double[] void Window(double data[]) Did you compiler swallow this? :wtf: You should be doing something like this (if I get your point):
double *Window(double *data, size_t count)
{
return data;
}