== operator does implicit conversions.
=== exists so you can omit these coercions when you don't need them or don't want them to apply. In many other languages, including dynamic ones (e.g. Python), implicit conversions are vastly less frequent. That is, integers may be converted to floats when doing math or comparing, but
"1" won't go along with
1. In those languages, the
== operator is basically the equivalent of looser language's
To pick up the example, Java goes even further - its
== will only consider two expressions equal if the evaluate to exactly the same reference, i.e. are the same objects (primitive types are, as usual, an exception). You can't get any stricter. What should a
=== do, consider two references equal only if they resulted from the same expressions? ;-)