Explain the difference between == and === in JavaScript.
Answer Posted / hr@tgksolutions.com
• == (Abstract Equality) compares values without considering data type (performs type coercion).
o Example: 5 == "5" → true
• === (Strict Equality) compares both value and type.
o Example: 5 === "5" → false
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
When would you use var in your declaration and when you wouldn’t?
What are the requirements of web application using javascript?
What is a closure in javascript?
Is null === undefined?
How to get value of an element by class in javascript ?
Is JavaScript case sensitive? Give an example?
why we need java instead of c
What does javascript do?
How to test a string as a literal and as an object ?
Where should I put script tags?
Is a parabola a function?
Is javascript array dynamic?
What is hoisted in javascript?
What are the uses of javascript in web page designing?
How can a page be forced to load another page in javascript?