Count Occurs Once

L2 Easy Arrays & Hashing
Concept
When you need to know how many times each value appears, a Dictionary counting tally into value frequencies is the standard move.
Return how many distinct values in nums appear exactly once. Values that repeat do not count at all.
Examples
▸ nums = [1, 2, 2, 3, 3, 3]
→ 1
▸ nums = []
→ 0
▸ nums = [5]
→ 1
Progressive Hints
Hint 1 · Nudge
You need to know how often each value appears before you can decide which ones count.
Hint 2 · Plan
First tally every number into a frequency map. Then count how many entries have a tally of exactly 1 and return that.
Hint 3 · Approach
counts = a map from value to tally. For each n: counts[n] = counts[n] + 1. Then count the keys whose tally equals 1. Return that count.
Output
// Run your code to see the output here.