Hold down a single button to turn on both sirens of Code Car. Release the buttons to turn them off.
New Concept: Growing Your 'if' Statements
This lesson helps you build on the powers of the 'if' statement. If you completed the challenges, you now see that the 'if' statement can be used to combine a number of commands and control multiple outputs with a single button press. As the number of lines in your programs grows, try to keep looking for patterns or 'reversals' of the concepts you're using. For example, the challenge of keeping all of the lights off when the button was pressed has more to do with patterns and code structure than it does with any new code concept.