src:
class Solution:
def sumOfUnique(self, nums: List[int]) -> int:
ans = 0
mp = defaultdict(int)
for num in nums:
mp[num] += 1
for num in mp:
if mp[num] == 1:
ans += num
return ans
快乐初六