# Conditions in JavaScript

Conditions in JavaScript: Making Decisions with if and else, Combining Conditions with And, Or and Not, switch and the Conditional Operator.

Updated: November 14, 2026

1. [Making Decisions with if and else](https://www.ask-codey.com/lessons/javascript-conditions-if-and-else) (Novice): An if statement runs a block of code only when its condition is true, else gives the other path, and else if chooses between several, so your program can react to what's going on.
2. [Combining Conditions with And, Or and Not](https://www.ask-codey.com/lessons/javascript-conditions-and-or-not) (Apprentice): The logical operators && (and), || (or) and ! (not) join small true-or-false checks into one condition, so a single if can follow a real rule with several parts.
3. [switch and the Conditional Operator](https://www.ask-codey.com/lessons/javascript-conditions-switch-and-ternary) (Apprentice): A switch statement matches one value against a list of exact choices, and the conditional operator ? : picks one of two values in a single line, so a long chain of else ifs can say what it means.

Source: https://www.ask-codey.com/courses/javascript-in-depth/topics/javascript-conditions
