Résult of the execution of your code
Action functions available :
Test functions available :
Test your script
The goal of this exercise is to be able to correctly nest a conditional structure in a repeating loop.
Each day, the mail carrier puts a stack of letters into the mailbox. The envelopes come in three different colors – yellow, red and green. The robot must sort each letter into the box with the same color as the envelope. At the end of the program, the robot must return to the mailbox to be ready for the next day. Note, it is possible that on some days the mail carrier will not put any letters into the mailbox – so the robot will begin its task even though the mailbox is empty.
◊ ◊ ◊
© Rupert Meurice de Dormale 2017
All rights reserved, reproduction in whole or in part of the interface and / or the code forbidden without the written agreement of the author
The drawings of the robots are of Jean-Baptiste Sonnet.