← Accenture questions
CodingMedium

Find if number Z has X^Y = Z and X&Y = 0

Filed under Accenture

Given an array of integers, for each number Z, determine if there exist positive integers X and Y such that X XOR Y = Z and X AND Y = 0. This is possible if and only if Z has at least two bits set to…

You've read your 3 free write-ups

Sign up free to keep reading. Your account opens the first 10 questions of every company.

Related Accenture questions

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