IG Group interview question

What is the difference between '==' and '===' in JavaScript?

Interview Answer

Anonymous

29 July 2016

'==' tries to coerce one of the operands to match the other's type (for example: '5' == 5 will return TRUE...); '===' is more literal and compares the true types and values (...whereas, '5' === 5 returns FALSE).