counter-two-pass-uniqueness-pattern

Status: IN

The Counter + linear-rescan pattern (count occurrences first, then iterate in original order to find the kth/first unique element) is a recurring idiom across this repo's uniqueness problems.

Source: entries/2026/06/06/kth-distinct-string-in-an-array-solution.md

Depended on by

JSON