The Wayback Machine - https://web.archive.org/web/20220116231542/https://www.geeksforgeeks.org/web-technologies-questions-javascript-course-quiz-2-question-7/
Skip to content
Related Articles

Related Articles

Improve Article
Save Article
Like Article

Web technologies Questions | JavaScript Course Quiz 2 | Question 7

  • Last Updated : 18 Apr, 2019

What will be the output of the following code?




<script>
  let ans = 1;
  document.write( ans === '1');
</script>

(A) true
(B) false
(C) 0
(D) None of the above


Answer: (B)

Explanation: The strict equality operator compares both the value and the type of the operands.

Quiz of this Question

My Personal Notes arrow_drop_up
Recommended Articles
Page :

Start Your Coding Journey Now!