int[] x = new int[0];
int[] y = new int[0];
void setup()
{
size(200, 200);
}
void draw()
{
}
void mousePressed() { // Click to add a line segment
x = append(x, mouseX);
y = append(y, mouseY);
for (int i = 0; i<x.length; i++) {
println(x[i], y[i]);
}
println();
}
Answers
thank you! kind sir :)