Operators

Less than or equal (<=)

Try the free JavaScript compiler

Tests the inclusive upper bound. Comparisons involving NaN are false, so this is not universally interchangeable with negating >.

Formal Syntax & Structure

javascript syntaxjavascript
left <= right

Parameters & Attributes

NameTypeDescription
leftexpressionLeft operand.
rightexpressionRight operand; short-circuiting may skip evaluation where applicable.

Return Value

Boolean

Result of the operation.

Working Example

Example Snippetjavascript
console.log(5 <= 5);
JavaScript Reference