bubble sort

(redirected from Bubblesort)

bubble sort

[′bəb·əl ‚sȯrt]
(computer science)
A procedure for sorting a set of items that begins by sequencing the first and second items, then the second and third, and so on, until the end of the set is reached, and then repeats this process until all items are correctly sequenced.
McGraw-Hill Dictionary of Scientific & Technical Terms, 6E, Copyright © 2003 by The McGraw-Hill Companies, Inc.

bubble sort

A sorting technique in which pairs of adjacent values in the list to be sorted are compared and interchanged if they are out of order; thus, list entries "bubble upward" in the list until they bump into one with a lower sort value. Because it is not very good relative to other methods and is the one typically stumbled on by naive and untutored programmers, hackers consider it the canonical example of a naive algorithm. The canonical example of a really *bad* algorithm is bogo-sort. A bubble sort might be used out of ignorance, but any use of bogo-sort could issue only from brain damage or willful perversity.
This article is provided by FOLDOC - Free Online Dictionary of Computing (foldoc.org)

bubble sort

A sorting technique that is typically used for sequencing small lists. It starts by comparing the first item to the second, the second to the third and so on until it finds one item out of order. It then swaps the two items and starts over. The sort may alternate from the top of the list to the bottom and then from the bottom to the top. The name comes from the notion that items are raised or "bubbled up" to the top. See sort algorithm.
Copyright © 1981-2019 by The Computer Language Company Inc. All Rights reserved. THIS DEFINITION IS FOR PERSONAL USE ONLY. All other reproduction is strictly prohibited without permission from the publisher.
References in periodicals archive ?
An example of tagged code for the BubbleSort algorithm is presented in Listings 7.
A tagged source code of the BubbleSort algorithm used to count the number of comparisons and swaps.
It consists in evaluating the run-times of three well-known sorting algorithms: QuickSort, BubbleSort and InsertSort.
The empirical results show that the fastest sorting algorithm is Quicksort, followed by Insertsort, then by Bubblesort. This observation conforms to the theoretical time complexity.
Keywords: sorting algorithm, complexity, QuickSort, BubbleSort, InsertSort
Like Quicksort, Bubblesort is widely used, but not necessarily because of its efficiency, having O(n2) theoretical time-complexity, but because of its simplicity.
For this research were chosen the most used three programming languages (Java, C ++ and C #) in which were implemented the following sorting algorithms: QucikSort, BubbleSort and direct insertion sort, in order to find out which programming language provides the shortest run-time.
Commutation properties among bubblesort, stacksort and their duals.
Contrast this with bubblesort (which simply passes over a list as many times as necessary, swapping any two consecutive elements in the wrong order, until the entire list is sorted).
The film demonstrates two [n.sup.2] exchange methods, Bubblesort and Shakersort, and one n log n method, Quicksort [ILLUSTRATION FOR FIGURE 3 OMITTED].
This final fade out happens long before they are finished, since it would take another 54 minutes for Bubblesort to complete.
Multiple transforms may apply to a program; in the case of sort, it may be implemented by refining it into a bubblesort or a mergersort (Figure 3).