Where do algorithms live? C++ STL: free functions over iterators. Rust: on the slice. I built a 76-line Slice class to feel the difference. Contiguous containers hand it out and inherit sort/find/contains for free. Bonus: binary_search on unsorted data is a compile error. lmilz.dev/blog/2026/06...
Algorithms Belong in the Slice, Not the Container | Lars Milz
lmilz.dev