5 ms·
No, this is a really poor trivia question for JavaScript. The question itself is lacking an important detail: what is the type of a? As presented, I think it wo
by cpburns2009 9y ago
No, this is a really poor trivia question for JavaScript. The question itself is lacking an important detail: what is the type of a? As presented, I think it would be safe to assume a is a number and thus it cannot possibly true. However, if a can be an arbitrary object, then there apparently is some hacky incantation that can make it true.
- lucideer 9y agoYou seem to be thinking of it as a yes/no/definite answer question. Interview questions should elicit discussion and deconstruction of the subject. Through this you can get an impression of how a candidate approaches the question. Your breakdown being a good example of such discussion.