Users Manual

CLASS 2
50
Experiencing the LED SENSOR
‘if’ phrase
We have learned what the ‘if..or else..’ phrase is. There is a simpler phrase than this, too. It’s the ‘If’ phrase.
The block you see above is the ‘If’ block. It activates blocks inside if ‘if…’ is satisfied. If it is not satisfied, it skips
without doing anything. Now, let’s put in the condition we need.
If we operate the led sensor using the ‘if’ phrase, the led sensor will never turn off since there is no ‘or else’ part.
Let’s use the ‘If’ phrase to turn the led sensor on and off.
Connect the second button sensor with the main cell.
digital input
B
R
W
12345678
23
Left button sensor Right button sensor