Follow the Signs
Hard · Variables
The piles in the row are signs. A pile of 3 balls means "jump 3 squares ahead". Start on Karel's square, follow the signs from pile to pile, and when Karel lands on an empty square, put a ball there and stop.
The signs must still be there at the end, and some piles are never visited. Your code runs in several worlds.
Hint: count a pile by picking the balls up, then put them all back.
Next: Copy the Row