Benchmarked Golang's built-in map against a special-built statically-sized Hash Set implementation. It's surprising how much overhead (both in processing and memory) there is in general-purpose code, but it sure is nice to not have to solve the problems of DIY.
https://willbeason.com/2025/05/21/problem-2-1-deduplicating-a-linked-list-with-maps/
https://willbeason.com/2025/05/21/problem-2-1-deduplicating-a-linked-list-with-maps/
Comments