[MG]Collide the robots
Two robots are placed at different points on a straight line of infinite length. When they are first placed down, they each spray out some oil to mark their starting points.
You must program each robot to ensure that the robots will eventually crash into each other. A program can consist of the following four instructions:
You must program each robot to ensure that the robots will eventually crash into each other. A program can consist of the following four instructions:
- Go left one space
- Go right one space
- Skip the next instruction if there is oil in my current spot
- Go to a label
Comments
Post a Comment