Lesson 40: Ternary Operator in JavaScript

Like and if/else statement, the Ternary operator also helps us run certain code when a condition is met. However ternary operator is used in simple scenarios.