【发布时间】:2011-09-27 09:52:14
【问题描述】:
可能的重复:
Is there a difference between !== and != in PHP?
Javascript === vs == : Does it matter which “equal” operator I use?
在某些情况下检查不相等时,我看到使用!=,在某些地方我看到!==。这有什么区别吗?
例子:
var x = 10;
if (x != 10) {
//...
}
和
if (x !== 10) {
//...
}
【问题讨论】:
标签: javascript