In Java,
if ( i != 0 )
is the idiomatic way to check whether the integer i
differs from zero
.
If i
is used as a flag, it should be of type boolean
and not of type int
.
In Java,
if ( i != 0 )
is the idiomatic way to check whether the integer i
differs from zero
.
If i
is used as a flag, it should be of type boolean
and not of type int
.