Java Reference
In-Depth Information
if (0 <= ix && ix < array.length && array[ix] != 0) {
// ...
}
The range checks are done first. The value array[ix] will be accessed
only if ix is within bounds. There is no "conditional XOR " because the
truth of XOR always depends on the value of both operands.
9.2.4. instanceof
The instanceof operator evaluates whether a reference refers to an ob-
ject that is an instance of a particular class or interface. The left-hand
side is a reference to an object, and the right-hand side is a class or in-
terface name. You learned about instanceof on page 92 .
9.2.5. Bit Manipulation Operators
The binary bitwise operators are:
bitwise AND
&
bitwise inclusive OR
|
bitwise exclusive or ( XOR )
^
The bitwise operators apply only to integer types (including char ) and
perform their operation on each pair of bits in the two operands. The AND
of two bits yields a 1 if both bits are 1, the OR of two bits yields a 1 if
 
Search WWH ::




Custom Search