Question DSA-BIT-0036
EasyIn [4, 1, 2, 1, 2], every number appears twice except one. What does XOR-ing all the elements give?
- A.
0
- B.
1
- C.
10
- D.
4
Sign up free to see the answer and a step-by-step explanation.
Popular companies
Prepare company by company
Hiring pattern, syllabus, past questions and mocks for each company.
All companiesPractice by subject
Bit Manipulation question
In [4, 1, 2, 1, 2], every number appears twice except one. What does XOR-ing all the elements give?
0
1
10
4
Sign up free to see the answer and a step-by-step explanation.