gilbert189 @gilbert189

In JavaScript, [] == 0 is true.

In JavaScript, [0] == 0 is also true.

You might assume [] == [0] is true from this.

But no. JavaScript says it's false.

Jan 20, 2023, 11:04 PM
3

comments

It works with strings too, look:

In JavaScript, ““ == 0 is true.

In JavaScript, “0” == 0 is also true.

You might assume ““ == “0” is true from this.

But no. JavaScript says it’s false.

That's from my meme right

it’s a repost from the TBGs

but yeah I made it from yours