You cannot pass a multi-dimensional array to a function taking pointer-to-pointer. Particularly since in this case, you are intend to pass a single dimension array. Fixes:
int largest_lowest(point *a[], int len)
- > point a[]
, and
largest_lowest(&a, 7);
-> largest_lowest(a, 7);
Also, please note that the function-like macro INIT_POINT_ARRAY
is horrible practice and you must get rid of it. There is absolutely no reason why you should have a macro there.
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…