We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
- Lonely Integer
- Discussions
Lonely Integer
Lonely Integer
Sort by
recency
|
240 Discussions
|
Please Login in order to post a comment
Java using two hash sets which operations are O(1), therefore it is only needed to iterate whole array once.
explanation : a^a=0 a^0=a...so if the element is unique we get the element as the result