Hi guys, i was wondering if an array could be an argument of a function...
For example:
int points[10];
..........
void swap(int points){
int a[10];
a=points[1];
points[2]=points[1];
points[1]=a;
};
..........
Is this correct? And, if its not, is there any other way it could be done (pointers maybe?)?
You need to either put square brackets after points or make points an int* in the function parameter list.
I'd just figured it out muself... :)
But ty very much!