```
def singleNonDuplicate(self, nums):
start, end = 0, len(nums) - 1
while start < end:
mid = (start + end) / 2
if mid % 2:
mid -= 1
if nums[mid] == nums[mid + 1]:
start += 2
else:
end = mid
return nums[start]
```