Engineering Full Stack Apps with Java and JavaScript
Which statements about the output of the following programs are true?
public class TestClass{ public static void main(String args[ ] ){ int i = 0 ; boolean bool1 = true; boolean bool2 = false; boolean bool = false; bool = (bool2 & method1("1")); //1 bool = (bool2 && method1("2")); //2 bool = (bool1 | method1("3")); //3 bool = (bool1 || method1("4")); //4 } public static boolean method1(String str){ System.out.println(str); return true; } }
Select 2 options
A. 1 will be the part of the output.
B. 2 will be the part of the output.
C. 3 will be the part of the output.
D. 4 will be the part of the output.
E. None of the above