Q. What does the following return?

Code:
console.log(typeof null);
  • (A) null
  • (B) object
  • (C) undefined
  • (D) NaN
πŸ’¬ Discuss
βœ… Correct Answer: (B) object
Explanation: typeof null returns 'object' due to a historical bug in JavaScript.
Explanation by: Chandani
typeof null returns 'object' due to a historical bug in JavaScript.

πŸ’¬ Discussion


πŸ“Š Question Analytics

πŸ‘οΈ
97
Total Visits
πŸ“½οΈ
1 y ago
Published
πŸŽ–οΈ
Chandani
Publisher
πŸ“ˆ
90%
Success Rate