Boolean literals are the bssically a similar as source code , its mainly use for the representation for boolean values . and we also know as the boolean values are only signifies the true and false . its happn only in java language but in other language its not happening as such . java language is the different form other language . boolean t = true; // Legal boolean f = 0; // Compiler error!