Card 15 / 32: Given: 1. class Maybe { 2. public static void main(String[] args) { 3. boolean b1 = true; 4. boolean b2 = false; 5. System.out.print(!false ^ false); 6. System.out.print(" " + (!b1 & (b2 = true))); 7. System.out.println(" " + (b2 ^ b1)); 8. } 9. }
A)
Line 5 produces true.
B)
Line 5 produces false
C)
Line 6 produces true
D)
Line 6 produces false
E)
Line 7 produces false
Answer:
A) Line 5 produces true.
D) Line 6 produces false
E) Line 7 produces false
Previous Card | ← Previous Card Button |
Next Card | → Next Card Button |
Flip Card | Space-Bar |
|