1 2 3 4 5 6 7 8 9 10
class Solution { public: int singleNumber(vector<int>& nums) { int x = 0; for (int n : nums) { x = x ^ n; } return x; } };