Lowest price ever! Learn Generative AI for 48% less!
Get my discount0
var a=[12,26,"pawan",77]; var b=[12,26,"pawan",77];
Why a==b is not equal ?
3 Answers
0
because a and b hold two different objects, even if their items values are equals ^^
+ 4
Variables, a and b each contain only a reference to a location in memory. Not the value of theย object. The locations are separate, so the references are different, and theย comparisonย return false.
- 1
Oo I think