What would be the output of typeof NaN in JavaScript?

  • number
  • null
  • string
  • undefined
The output of typeof NaN in JavaScript is 'number'. This might seem counterintuitive, but it's because NaN is considered a numeric data type in JavaScript.
Add your answer
Loading...

Leave a comment

Your email address will not be published. Required fields are marked *