Two robots are each standing on a beacon, on a line of infinite length.They both execute the same code. Write the code to have them collide.Only use these commands:SKIPNB - skip the next line of code if not on a beacon MVR - move right one stepMVL - movel eft one stepJMP - goto label in the codehint: have both robots move to the right in a loop. if a robot passes a beacon, double its speed.
Two robots are each standing on a beacon, on a line of infinite length.They both execute the same code. Write the code to have them collide.Only use these commands:SKIPNB - skip the next line of code if not on a beacon MVR - move right one stepMVL - movel eft one stepJMP - goto label in the codehint: have both robots move to the right in a loop. if a robot passes a beacon, double its speed.
Answers:
No Answers yet. Be the first one to submit an answer!
To post an answer to this question, please login or sign up.


Reddit This!