G'day,
I wanna draw a rectangular spiral with a/several for-loop(s) with my Rover. On each field, there shall be a cross which illustrate that.
So already have
Actually, the first time it should drive and turn right, the second time it should drive twice and then turn right and so on.
I already had the idea with incrementing after each run, but I don't know how to implement it.
Can you help me?
1 2 3 4 5 6 | for ( int i= 0 ; i< 5 ;++i) { for ( int j= 0 ;j< 1 ;++j) { drive(); } turn("right); } |