Abstract
Traditional INSERTION SORT runs in O(n2) time because each insertion takes O(n) time. When people run INSERTION SORT in the physical world, they leave gaps between items to accelerate insertions. Gaps help in computers as well. This paper shows that GAPPED INSERTION SORT has insertion times of O (log n) with high probability, yielding a total running time of O(n log n) with high probability.
Original language | English (US) |
---|---|
Pages (from-to) | 391-397 |
Number of pages | 7 |
Journal | Theory of Computing Systems |
Volume | 39 |
Issue number | 3 |
DOIs | |
State | Published - Jun 2006 |
ASJC Scopus subject areas
- Theoretical Computer Science
- Computational Theory and Mathematics