Conditionals
The Wolfram Language's symbolic character allows a powerful unification of the notion of conditionals in programming and in mathematics.
Testing Expressions »
Equal(==) ▪ Unequal(!=) ▪ SameQ(===) ▪ And(&&) ▪ IntegerQ ▪ ...
Procedural Conditionals
If — test if a condition is true, false, or of unknown truth value
Which — test which of a sequence of conditions are true
Switch — switch based on a value, with patterns allowed
Mathematical Function Conditionals »
Piecewise — an arbitrary piecewise function
ConditionalExpression — expression defined under condition
UnitStep ▪ Sign ▪ Mod ▪ Floor ▪ Boole ▪ DiscreteIndicator ▪ ...
Pattern-Based Conditionals »
Replace — replace an expression if a rule applies
Condition (/;) — specify an arbitrary condition for a pattern to match