Goal: In the Assignment and Comparison Operators lesson, we learned:
- The difference between
+= assignment operator
- Comparison operators, including
Take time to practice using each of these operators by completing the exercises listed below.
- What is the difference between a comparison operator and an assignment operator?
- What is a boolean? What does it represent?
- How is the
+= operator different than the
Assignment & Comparison Practice
Practice assigning and comparing:
- Set two variables equal to two different numbers. Use a comparison operator to compare these two variables. Change one of their values by using the
/= operator. Then, compare their values again.
- Try out the
- Try to use the