Great use of JavaScript's weird + operator.
The whole trick stems from the fact that !$ == false and !$+$ == "false"
The whole trick stems from the fact that !$ == false and !$+$ == "false"
![] == false because [] exists.
false + [] == 'false' because anything added to an array will become whatever that is as a string plus the contents inside the array.
2 + [] is also a string "2"
2 + [2,2] will become "22,2" (string)
What I don't get though, wouldn't you still need to call eval() on it to do anything with it? Or does javascript do a 'implied eval' when you try to call a string?