Given an array A containing 2 x N+2 positive numbers, out of which 2 x N numbers exist in pairs whereas the other two number occur exactly once and are distinct. Find the other two numbers.
- Time : O(n)
- Space : O(1)
1 | class Solution |
Given an array A containing 2 x N+2 positive numbers, out of which 2 x N numbers exist in pairs whereas the other two number occur exactly once and are distinct. Find the other two numbers.
1 | class Solution |