Comment

Comment by mbnull

> TL;DR: If you don’t need to preserve order of the elements, sort the slice first and dedupe.

And if you need to preserve order of elements, there is always sort.Stable!

parent mbnull 3 years ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton