On running the above program, we get the following output: Program 4: To display one of the two alternate messages. <!DOCTYPE HTML> <HTML> <HEAD> <TITLE> if-else statement </TITLE> </HEAD> <BODY> Conditional Statements in JavaScript 83