js ===
5 =='5' // true: ignores type
5 === '5' // false: includes type
js ===
5 =='5' // true: ignores type
5 === '5' // false: includes type
javascript equality
18 === 18 // true
18 === 19 // false
`18` == 18 // true
`18` === 18 // false
// == : loose equality operator (date type IS NOT relevant)
// === : strict equality operator (date type IS relevant)
// Note: the same applies for not equal
`18` != 18 // false
`18` !== 18 // true
check equality numbers javascript
function isSameNum(num1, num2) {
var num1
var num2
if ( num1 === num2 )
return true;
else
return false;
}
Copyright © 2021 Codeinu
Forgot your account's password or having trouble logging into your Account? Don't worry, we'll help you to get back your account. Enter your email address and we'll send you a recovery link to reset your password. If you are experiencing problems resetting your password contact us