Why Syntax error appears on the following if condition
Hi I have a following if condition in java
if ((i%3)==0)
do some work
else if ((i%3 || i%5)==0)----syntax error appears on this line
do some work
And it is showing me following syntax error... Multiple markers at this
line - The operator || is undefined for the argument type(s) int, int -
Syntax error on token "OR", . expected - i cannot be resolved or is not a
field
can any one please tell me how can i fix this one ??
No comments:
Post a Comment