Get the latest tech news

This New Algorithm for Sorting Books or Files Is Close to Perfection


The library sorting problem is used across computer science for organizing far more than just books. A new solution is less than a page-width away from the theoretical ideal.

Last year, in a study that was presented at the Foundations of Computer Science conference in Chicago, a team of seven researchers described a way to organize items that comes tantalizingly close to the theoretical ideal. “It’s a very important problem,” said Seth Pettie, a computer scientist at the University of Michigan, because many of the data structures we rely upon today store information sequentially. In a 2022 paper, Bender, Kuszmaul, and four coauthors created just such an algorithm—one that was “history independent,” non-smooth, and randomized—which finally reduced the 1981 upper bound, bringing the average insertion time down to (log n) 1.5.

Get the Android app

Or read this on Wired

Read more on:

Photo of Files

Files

Photo of perfection

perfection

Photo of new algorithm

new algorithm

Related news:

News photo

Automating the cleaning of macOS-specific ( ._ and .DS_Store) files on Eject

News photo

Samsung Galaxy S25 Ultra Review: So close to perfection

News photo

Backblaze seemingly does not support files greater than 1 TB