if (expression) { Statement(s) to be executed if expression is true } else { Statement(s) to be executed if expression is false }Example
let result; let age = 14; if (age > 18) { result = "You have right age now"; } else { result = "You are under age"; } Output :- "You have right age now"