Question

What will be the output of the following Java code?     int x = 5;     int y = x++ + ++x;     System.out.println(y);

A 10
B 11
C 12
D 13
E Compilation error
Practice Next

Hey! Ask a query

🎓
Think You're Ready for RBI Grade B?
RBI Grade B 2026 Phase 1 Memory Based Paper
  • 200 Questions with Detailed Solutions
  • Section-wise Coverage (GA, English, Quant & Reasoning)