Conditions (Part 2)

This series of challenges is similar to the previous one, but with more colors to check.

To properly complete the missions, you will need to reset and run the program a few times. Your robot must handle all possible randomization without changes to the program.

Example

Reset the world a few times to see where the green box may appear...

In this example challenge, the box may appear on the left (red), right (green), or front (yellow) of the robot.

We can use a condition to check the color of the ground, then decide which way to move.

Do we really need an "ELSE IF" for the yellow? Can we just use an "Else"?

Challenges

For each challenge, click on the Simulator Tab, then the Mission button to see the mission you need to do.

Follow the instructions and note down the special Code after doing the challenge successfully!

Conditions Challenge 6

Conditions Challenge 7

Conditions Challenge 8

Conditions Challenge 9

Conditions Challenge 10

Conditions Challenge 11

Conditions Challenge 12