#136

Single Number

easy · 77.4% accepted · 18,713 likes · top 89%

array · bit manipulation

⊣ practice⊣ quiz⊣ open on leetcode ↗

Description

Given a non-empty array of integers nums, every element appears twice except for one. Find that single one.

You must implement a solution with a linear runtime complexity and use only constant extra space.

Solution