var singleNumber = function(nums) {
const hash = {};
for (const el of nums) {
if (!hash[el]) {
hash[el] = 1;
} else {
delete hash[el]
}
}
return Object.keys(hash)[0];
}
For further actions, you may consider blocking this person and/or reporting abuse
Top comments (0)