JavaScript - Operators and Loops:
When making a condition-based-decision, Comparison and Logical Opertators can be used:
We have 8 Comparison Opertators (reaturn single boolean value):
- == : equal to by value
- ===: strictly equal to by value and type
- !== : not equal to by value
- !===: not strictly equal to by value and type
- ’>’:greater than
- ’>=’:greater than or equal
- ’<’:less than
- ’<=’:less than or equal
Logical Opertators (allow the comparison of more than one comparison operators):
LOOPS (FOR - WHILE - DO WHILE)
- Loops allow the execution of a code block for a specified number of times, as long as the condition returns a TRUE value.
- A Loop Counter consists of three main elements: (Intialization Variable - Condition - Counter Update)