Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Apprendre OR Logical Operator | Section
Practice
Projects
Quizzes & Challenges
Quizzes
Challenges
/
JavaScript Essentials for Beginners - 1768407374405

bookOR Logical Operator

The || (OR) operator is used for defining the "or" relation between two or more expressions.

It returns true if any of the expressions evaluate to true.

Example:

12345
let a = 9; if(a < 10 || a > 30) { console.log("Condition Matched"); }
copy

The above code output "Condition Matched" when a is less than 10 OR a is greater than 30.

question mark

What is the result of the following expression if x = 5?

Select the correct answer

Tout était clair ?

Comment pouvons-nous l'améliorer ?

Merci pour vos commentaires !

Section 1. Chapitre 43

Demandez à l'IA

expand

Demandez à l'IA

ChatGPT

Posez n'importe quelle question ou essayez l'une des questions suggérées pour commencer notre discussion

bookOR Logical Operator

Glissez pour afficher le menu

The || (OR) operator is used for defining the "or" relation between two or more expressions.

It returns true if any of the expressions evaluate to true.

Example:

12345
let a = 9; if(a < 10 || a > 30) { console.log("Condition Matched"); }
copy

The above code output "Condition Matched" when a is less than 10 OR a is greater than 30.

question mark

What is the result of the following expression if x = 5?

Select the correct answer

Tout était clair ?

Comment pouvons-nous l'améliorer ?

Merci pour vos commentaires !

Section 1. Chapitre 43
some-alt