THE IDEA
Understand the concept
An if statement runs a block when its condition is truthy; else provides another path. Keep conditions explicit and order related cases carefully so a broad condition does not hide a more specific one.
WORKED EXAMPLE

LESSON 03 ยท JAVASCRIPT
Conditions let a program choose a path based on a true-or-false test.
THE IDEA
An if statement runs a block when its condition is truthy; else provides another path. Keep conditions explicit and order related cases carefully so a broad condition does not hide a more specific one.
WORKED EXAMPLE