Could we use `Enumerable#partition` here instead?