Computer Science, asked by mola13bap, 1 month ago

What will be result of the following statement

boolean a= true;

boolean b = false;

System.out.println( a&&b);

Answers

Answered by abhinavmike85
5

\huge \: \mathfrak {\:{\underline{\pink{answer}}}}

\sf \: false

\huge \: \mathbb{\underline{\green{explanation}}}

"&&" in java results in true if and only if both the conditions (or statements) are true.

In the question, one statement is true(a is true) and one is false(b is false) so the the output will be false.

Hope it helps

Similar questions