โ† PayU questions

Evaluate bitwise expression n & (n-1) == 0

Filed under PayU

The question

Determine for what values of n the expression (n & (n-1) == 0) evaluates to true.

No write-up yet. Related questions below have one.

Related PayU questions

Collected from public candidate posts and coding forums. Updated Nov 2026.