Step 7: How to Modify an IF/THEN block

Goal:


When working with IF/THEN blocks, sometimes you want your code to check for more than 1 input, so we need to add and ELSE IF portion to our IF/THEN block.

Sometimes, we also want our code to do a specific thing if our IF/THEN can match any of its check to input we give it, so we need to add and ELSE portion to our IF/THEN block.

Steps:

  1. Select the blue gear icon in the top left corner of the IF/THEN block.
  2. In the small window that appears, drag an ELSE IF block from the left into the mouth of the small IF block inside of the small window.
  3. Still in the small, drag an ELSE block from the left into the mouth of the small IF block inside of the small window.
  4. If you ever want to add more options for your IF/THEN block to check for, you can simply follow these steps to add another ELSE IF portion to your block.

Code:


Click to replay