I have a function that takes an x an y coordinate as parameters
void storecoords(float x, floaty)
I need to store a number of x,y coordinates in an array such that:
Array [x1 ][x2][x3][x4][x5] ...
[y1 ][y2][y3][y4][y5] ...
As the x y coordinates are recieved by the function I need to
1) check if the coordinates are in the array.
2) if if the coordinates are do nothing.
3) if the coordinates are not in the array: add the coordinates to the array.
n.b the array must be able to grow dynamically as more and more coordinates are added?
Any suggestions appreciated?