In addition to “normal” comparison operators (see the links below), JavaScript has a unique comparison operator that can assign values rather than just return a boolean true or false. This is called the “Conditional (Ternary) Operator”. It follows this syntactical construction: variablename = (condition) ? value1 : value2 The question mark means: If the condition … Continue reading JavaScript: How to use the conditional ternary operator