Start learning →

How is the expression a & b == 7 syntactically parsed by Java?

Aa & (b == 7)
B(a & b) == 7
Ca == (b & 7)
D(a == b) & 7
Answer & Solution
Correct answer: A. a & (b == 7)
Equality operators hold higher precedence than bitwise AND, so b == 7 binds first.
Practise this question with Quill — ICSE Class 8 →

Keep practising Operators in Java

Browse all Operators in Java questions for ICSE Class 8, or explore more Computer Applications topics.

Start a Operators in Java lesson →