No, they are not the same. !=
is checking whether two things are "not equal" to each other. You can use this on integers... e.g. (6 != 7)
would evaluate to true, and (6 != 6)
would evaluate to false.
x == false on the other hand, is checking whether x is specifically equal to the value false
.
6 == false
would evaluate to false, and true == false
would evaluate to false, but false == false
would evaluate to true!