What Does 1 And 0 Mean In Javascript

    Table of contents

What does !1 and !0 mean in Javascript?

Tags: javascript Answers: 1 | Viewed 60,471 times

Possible Duplicate:

return !1 in javascript

In a JavaScript file I had to read today, there was a line where a variable was declared like a factorial, like this :

var myVariable = !1;

and then something similar was used as parameter in a function like this :

return variable.myFunction(!0);

Can anyone explain me what the exclamation mark means in this context and eventually, why this is generally used for (benefits) ?

Thank you in advance !

Some Answers For What Does 1 And 0 Mean In Javascript

Please leave your answer here: