According to Firebug console, we have the following in JavaScript:
>>> [''] == ''
true
>>> [''] == ['']
false
Finding Python to be much more logical here, I'd expect it to be the way round. Anyway, I can understand the second one — apparently two different objects never compare equal to each other, — but what is the reason for the first to give true
? What string would ['', '']
compare equal to?