What is a boolean?
The words true and false are special keywords in Java and are boolean literals.
Declaration and Assignment
You can declare and assign boolean variables as follows:
boolean isProgrammingFun = true; boolean isCOMP110AnEasyA = false;
Control Flow Statements and booleans
Control flow statements (conditionals and loops) depend on boolean values. Being comfortable with the idea of a boolean, boolean variables, and its logical operators will improve your ability to make effective use of control flow statements tremendously.