1

I ran into the expression a !== a in someone else's code:

function isEmpty(a) {
    return a === undefined || a === '' || a === null || a !== a;
}

The only case where I can think of the final expression evaluating to true is when isNaN(a). Are there any other values of a for which a !== a is true?

Snowball
  • 11,102
  • 3
  • 34
  • 51

0 Answers0