Lably
Skip to content

Bubble sort

Simple sorting algorithm using comparisons

  • 12 min read
  • 7 chapters
  • 2 labs on Lably

Learn it on Lably

It performs poorly in real-world use and is used primarily as an educational tool. More efficient algorithms such as quicksort, timsort, or merge sort are used by the sorting libraries built into popular programming languages such as Python and Java.

History

The earliest description of the bubble sort algorithm was in a 1956 paper by mathematician and actuary Edward Harry Friend, Sorting on electronic computer systems, published in the third issue of the third volume of the Journal of the Association for Computing Machinery (ACM), as a "Sorting exchange algorithm." Friend described the fundamentals of the algorithm, and although initially his paper went unnoticed, some years later it was rediscovered by many computer scientists, including Kenneth E. Iverson, who coined its current name.

Sign in to keep reading

6 more chapters are free with a Lably account.

More in Computing and communication