Skip to content

Instantly share code, notes, and snippets.

@yschen25
Created March 8, 2022 04:13
for (let i = 0; i < arrLength; i++) {
if (map.has(arr[i])) {
map.set(arr[i], map.get(arr[i]) + 1);
} else {
map.set(arr[i], 1);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment