enow.com Web Search

Search results

  1. Results from the WOW.Com Content Network
  2. Sorting algorithm - Wikipedia

    en.wikipedia.org/wiki/Sorting_algorithm

    Stable sort algorithms sort equal elements in the same order that they appear in the input. For example, in the card sorting example to the right, the cards are being sorted by their rank, and their suit is being ignored. This allows the possibility of multiple different correctly sorted versions of the original list.

  3. Timsort - Wikipedia

    en.wikipedia.org/wiki/Timsort

    This is done by merging runs until certain criteria are fulfilled. Timsort was Python's standard sorting algorithm from version 2.3 to version 3.10, [5] and is used to sort arrays of non-primitive type in Java SE 7, [6] on the Android platform, [7] in GNU Octave, [8] on V8, [9] Swift, [10] and inspired the sorting algorithm used in Rust. [11]

  4. Selection sort - Wikipedia

    en.wikipedia.org/wiki/Selection_sort

    Selection sort. In computer science, selection sort is an in-place comparison sorting algorithm. It has an O (n2) time complexity, which makes it inefficient on large lists, and generally performs worse than the similar insertion sort. Selection sort is noted for its simplicity and has performance advantages over more complicated algorithms in ...

  5. Quicksort - Wikipedia

    en.wikipedia.org/wiki/Quicksort

    Quicksort is an efficient, general-purpose sorting algorithm. Quicksort was developed by British computer scientist Tony Hoare in 1959 [ 1 ] and published in 1961. [ 2 ] It is still a commonly used algorithm for sorting. Overall, it is slightly faster than merge sort and heapsort for randomized data, particularly on larger distributions.

  6. Bubble sort - Wikipedia

    en.wikipedia.org/wiki/Bubble_sort

    Bubble sort, sometimes referred to as sinking sort, is a simple sorting algorithm that repeatedly steps through the input list element by element, comparing the current element with the one after it, swapping their values if needed. These passes through the list are repeated until no swaps have to be performed during a pass, meaning that the ...

  7. Merge sort - Wikipedia

    en.wikipedia.org/wiki/Merge_sort

    In computer science, merge sort (also commonly spelled as mergesort and as merge-sort[2]) is an efficient, general-purpose, and comparison-based sorting algorithm. Most implementations produce a stable sort, which means that the relative order of equal elements is the same in the input and output.

  8. Sorting - Wikipedia

    en.wikipedia.org/wiki/Sorting

    Sorting is a common operation in many applications, and efficient algorithms have been developed to perform it. The most common uses of sorted sequences are: enabling processing of data in a defined order. The opposite of sorting, rearranging a sequence of items in a random or meaningless order, is called shuffling.

  9. Cycle sort - Wikipedia

    en.wikipedia.org/wiki/Cycle_sort

    Cycle sort is an in-place, unstable sorting algorithm, a comparison sort that is theoretically optimal in terms of the total number of writes to the original array, unlike any other in-place sorting algorithm. It is based on the idea that the permutation to be sorted can be factored into cycles, which can individually be rotated to give a ...