boolean literal in Java
Although in C (and some other languages) it is common to use numbers to represent true or false , this will not work in Java. ``` boolean t = true; // Legal boolean f = 0; // Compiler error! ```
Although in C (and some other languages) it is common to use numbers to represent true or false , this will not work in Java. ``` boolean t = true; // Legal boolean f = 0; // Compiler error! ```