Salesqueen Software Solution

Download Free Estimation Now Click Here
Notifications
Clear all

what is the difference between '==' and '===' operators in javascript?

3 Posts
3 Users
0 Reactions
145 Views
Posts: 100
Topic starter
(@sowmiya)
Estimable Member
Joined: 2 years ago

== operator vs=== operator

2 Replies
Posts: 100
 Kavi
(@kavi)
Estimable Member
Joined: 2 years ago

The primary distinction between the == and === operators in javascript is that the former converts the operands' data types before comparison, whilst the latter compares both the operands' values and their data types.

Reply
Posts: 19
 M.
(@m)
Active Member
Joined: 2 years ago

The "==" operator performs the appropriate type conversions before testing for equality and checking for abstract equality.

When comparing two values, the "===" operator will return false if the two values are not of the same type because it does not perform a type conversion.

Reply
Share: