comparison operator in javascript code example

Example 1: equal to or more than javascript

//Equal to or more than
a >= b
//Equal to or less than
a <= b

Example 2: === javascript

// ===	means equal value and equal type
var x = 5

// true
x === 5

// false
x === "5"

Example 3: js comparison operators

Javascript Comparison Operators
== Equal to
=== Equal value and equal type
!= Not equal
!== Not equal value or not equal type
> Greater than
< Less than
>= Greater than or equal to
<= Less than or equal to
? Ternary operator

Example 4: js !==

var x = 5;

// === 	equal value and equal type
// e.g. 1. 
x === 5 returns true

// e.g. 2.
x === "5" returns false

// !== not equal value or not equal type
// e.g. 1.
x !== 5 returns false

// e.g. 2.
x !== "5" returns true

// e.g. 3.
x !== 8 returns true