Adjust the program so that if another parameter, E, is 1 then the line is drawn in black (as here), & if it is
0 then the line is drawn in white (using
UNPLOT
). You can then rub out a line you've just drawn by
undrawing it.
the N steps D2. Imagine a Monopoly board with M squares round
the edge, numbered from 0 to M-1. The square you are on at any
time is number S, starting at the corner opposite G0. Each move
takes you N squares round the board, & in the straight line on the
screen you make either a left-right/ up-down step (if you pass GO on
the board), or a diagonal step otherwise. Since your total journey on
the board is M*N steps, or right round N times, you pass GO N times
& evenly spaced out in your M steps are N left-right/up-down steps.