O'Reilly logo

JavaScript Absolute Beginner’s Guide by Kirupa Chinnathambi

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

18. Booleans and the Stricter === and !== Operators

In This Chapter

Learn more about what goes on behind true and false

Understand what boolean objects and functions do

Find out the difference between simple inequality operators and strict inequality operators

While it’s polite to say that all types are interesting and fun to be around, you and I both know that is a lie. Some types are just boring. The boolean type is one such example. Here is the reason why. Whenever you initialize a variable using either true or false, you create a boolean:

var sunny = false;var traffic = true;

Congratulations. If you know just this, you are 80% of the way there in fully understanding how booleans operate. Of course, 80% isn’t really adequate when you ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required