← Accenture questions
CodingMedium

Count pairs with arr[i]^arr[j] > arr[i]&arr[j]

Filed under Accenture

Given an array of integers of size up to 1e5, find the count of pairs (i, j) such that i < j and arr[i] ^ arr[j] > arr[i] & arr[j]. An O(N) solution is required.

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.