ExamVeda
Login
Home
This question belongs to Java Program Flow Control
Flow Control
?

What will be the output?
public class Test{
        public static void main(String[] args){
                int x=10, y=0;
                if(x && y){
                        System.out.print("TRUE");
                }
                else{
                        System.out.print("FALSE");
                }
        }
}

Answer & Solution
Correct Answer: Option C
bad operand types for binary operator '&&'
if(x && y)
Examveda
Question posted by Examveda
Community

Join the Discussion

3 Comments
Tejesh
Tejesh 8 years ago
boolean a= true, b= true;
if (a && b)
this is the correct way
Deepak Deepak
Deepak Deepak 9 years ago
any one can Convey the answer?
Tabinda Hayat
Tabinda Hayat 9 years ago
What will be the output and why?