JavaScript less than or equal to operator

 JavaScript less than or equal to operator

Doers JavaScript lesson, Section 2. #Doers

JavaScript offers less than or equal to operator to compare values and return true or false depending on the comparison. 

This operator additionally check if the number is less than or equal to before returning the results. In that regards it's a little different than the less than operator. 


Less than or equal to operator is denoted by the <= symbols. This is part of comparison operators in JavaScript. 

If the number on the left is less than or equal to the number on the right, it returns true, otherwise it returns false.

Again, Implicit type conversion is performed while using this operator.


Post a Comment

0 Comments

React