JavaScript Ternary Operator

JavaScript Ternary Operator 2

The JavaScript Ternary Operator also called a Conditional Operator. The JavaScript Ternary Operator returns the statement depends upon the expression result. This JavaScript Conditional Operator used in the decision-making process. The syntax of a conditional Operator in JavaScript Programming language is Test_expression ? statement1: statement2 If the given test expression is true, it returns statement1. If the … Read more