Java Reference
In-Depth Information
value 100 because a byte can hold the value 100. However, when the attempt is made to
assign b the value 257, information loss occurs because 257 exceeds a byte 's maximum
value. Finally, no information is lost, but a cast is needed when assigning a byte value to a
char .
Operator Precedence
Table 2-3 shows the order of precedence for all Java operators, from highest to lowest. This
table includes several operators that will be discussed later in this topic. Although technic-
ally separators, the [] , () , and . can also act like operators. In that capacity, they would have
the highest precedence.
Table 2-3 The Precedence of the Java Operators
Try This 2-2 Display a Truth Table for the Logical Operators
 
Search WWH ::




Custom Search