Hello and welcome.
In this fit you are be introducing you to the javascript logical operators javascript logical operators
who are used to determine the logic between variables or values.
So this is a basic table chores due to logical operators.
The first is called The Ant and is represented by the assigned symbol.
What that does it checks if all the conditions are met.
And it will return boolean result.
Either true or false.
If all the conditions are met it will return true.
If not Ireton is false.
The links is the OR operator which is represented by the pipe symbol.
He checks if any condition has been met and it will return a true boolean result.
So the key distinction between the and the or is that when are using it and to check conditions or the
conditions has to evaluate to true if they are not met then it will return false Boolean result unresolved
bisk remains true or false in the operator.
You only have to satisfy one condition.
It will return true result.
So let me quickly illustrate how the logical operators are used in the console.
So I'm going to start by creating a couple of variables with variable X..
I give it a value of 7.
Great are not a variable.
When a call is variable y and I give it a value of 6 now I can use the logical operators to check the
condition so I can see X is less than 10.
If X is less than 10 and Y is greater than 6 this will evaluate to be false because the first condition
is true.
X is less than 10 but the second condition is false because Y is not greater than 6 so it would evaluate
to be false.
So if I use the OR operator with the same condition it will return true because one part of the condition
is true.
So it will return everything as true.
For example the same illustration if I come in and say X is less than 10 or Y is greater than 6.
This will evaluate to be true because the first part of the condition is true X is less than 10.
So that's basically how you use a logical operator in a nutshell.
Once you understand this basic use of it then it will be able to make more sense when you start using
it later.
Thank you for watching and bye for now.