Shuffling algorithm library
Simple library that implements a shuffling algorithm based on Spotify’s blog post.
It solves shuffling problem when there is no need for ‘real’ randomised shuffling. Imagine sorting a list of music tracks when we don’t want tracks from same artist or same genre next to each other. This algorithm tries to logically group list items and distribute each group’s items as uniformly as possible throughout the list.
Make sure to setup Deno. Run changes against tests:
> deno test