Solving Single Number in go. Please try yourself first to solve the problem and submit your implementation to LeetCode before looking into solution.

Problem Description

Note:

Your algorithm should have a linear runtime complexity. Could you implement it without using extra memory?

Example 1:

Input: [2,2,1]
Output: 1

Example 2:

Input: [4,1,2,1,2]
Output: 4

See the full details of the problem Single Number at LeetCode

Originally posted at: @github.com/halfrost/LeetCode-Go