+ 1

What's the difference between two things being identical and two things being equal?

Js operators

17th Dec 2019, 3:55 PM
Iloka Nadia
Iloka Nadia - avatar
2 odpowiedzi
+ 2
Maybe identical this numbers 2 == 2 (true) 2 === 2 (true) And equal is '2' == 2 (true) but '2' === 2 (false) Becouse '2' - string and 2- number They equal, but no identical
17th Dec 2019, 4:42 PM
Yaroslav Vernigora
Yaroslav Vernigora - avatar
0
Identical is the same thing. Equal is is the same value. (at least that’s how I see it)
17th Dec 2019, 3:56 PM
Jax
Jax - avatar