Calculating the order of numbers is a rather mundane task, but creating a list of many of them, maybe writing it on paper, can take some attempts! This is why we created this handy ordering numbers calculator.

Calculating the order of numbers: the human way

Humans are particularly good at sorting items, numbers, letters, and more complex quantities like weight, length, angles, and so on. We can do it with a mixture of analytical skills, logic, and intuition.

Therefore, it's impossible to describe a generic algorithm we use to sort items. Take this list of numbers:


You may take the 22 as the first number, ignore the 5858 (but remember that it's somewhere there), and see the 149149 and decide that it's okay at the end of the list. You may remember the 5858 when you meet the 7373, and right after, you'd find the only negative number of the list, and place it at the beginning, maybe hoping that nothing smaller will appear. Numbers enter and exit your memory as you place them, while the list somehow gets completed. A list of items extracted by a finite set is even easier to sort, as we can place items on two sides.

But even the fastest human has to bow in front of the sorting skills of computers.

How do computers order numbers: sorting algorithms

Computers sort arrays (usually of numbers) using one of many possible algorithms. Just for fun, let's see some of them.

Insertion sort

In the insertion sort algorithm, we compare one element at a time to the ones we placed in an ordered list that grows with time. We follow this algorithm:

  1. We place the first element in the ordered array.
  2. We take the second element and compare it with the one in the ordered array. If smaller, we place it on the left; if larger, on the right.
  3. We take the third element of the array and compare it with the rightmost element in the ordered array; if larger, we place it at the end; if smaller, we compare it with the previous element of the array and follow the same rules (if larger, we put it there, if smaller we move it to the left).
  4. Repeat these steps until all elements of the original array are considered.

Admittedly, this is not an efficient sorting algorithm, but it works!

Bubble sort

Bubble sort considers a pair of elements of the array to be ordered, from left to right. If the pair is not in order, it switches the element. The algorithm then shifts one position and repeats the process. Once it reaches the end of the array, it restarts from the beginning. The algorithm stops when it doesn't perform any switch during the passage over the array.

Merge sort

In this algorithm, the list is split into single elements that are then combined in ordered sublists, starting from length 2, and merged into larger, ordered lists until the final order is achieved. At every merging step, the algorithm picks the list's minimum value and compares it with that already sorted.

Computer scientists are still researching sorting algorithms, aiming to achieve the purpose in the smallest possible time (number of operations) or with the lowest consumption of resources.

How to use our ordering number calculator

To use our ordering number calculator, simply start inserting numbers in the fields. If you need more numbers, more fields will appear. You can sort up to 50 numbers!


How do I sort numbers in ascending order?

To sort numbers in ascending order:

  1. Take your unordered list.
  2. Compare the first element with the second one. If they are not in order, switch their positions.
  3. Compare the second element with the third one. If they are not in order, switch their positions.
    • Compare now the third element with the first one: if they are in the wrong order, invert them.
  4. Proceed with the comparison. Eventually, at the end of the list, you may have to compare the number with all the elements of the list.

This is a relatively inefficient way to sort a list!

How can I sort a long list of numbers in an efficient way?

To sort a long list of numbers quickly and without errors, you can use a paper-and-pen implementation of the bubble sort algorithm.

  1. Take the first pair of elements of the list. Switch their position if they are not in order.
  2. Move one element to the right and perform the same operation.
  3. Once you reach the end of the list, start again from the beginning.
  4. The list is ordered when you don't have to perform any switches!

How do I sort the list {4,7,1,9,3,6,2} using bubble sort?

To sort the list {4,7,1,9,3,6,2} with bubble sort:

  1. Take the first pair of elements: {4,7}. It's in order; move on.
  2. Take the second pair: {7,1}. Switch them: {1,7}.
  3. Move on: the next pair is {7,9}; leave it.
  4. Next one, {9,3}: switch it ({3,9}).
  5. Proceed: {9,6} becomes {6,9}.
  6. Final pair: {9,2} becomes {2,9}.

The result is: {4,1,7,3,6,2,9}.
Repeat the procedure: you'll get this array: {1,4,3,6,2,7,9}. From here, you'll meet:

  1. {1,3,4,2,6,7,9}.
  2. {1,3,2,4,6,7,9}.
  3. Finally, the last switch would give you: {1,2,3,4,6,7,9}.
Davide Borchia
Values (enter up to 50 numbers)
Check out 39 similar descriptive statistics calculators 📊
5 number summary5★ rating averageCoefficient of variation… 36 more
People also viewed…

5 number summary

The 5 number summary calculator will give you the five most important statistical parameters of your dataset: minimum, first quartile, median, third quartile, and maximum.

Secretary problem (Valentine's day)

Use the dating theory calculator to enhance your chances of picking the best lifetime partner.


This sensitivity calculator will introduce you to this key concept related to the accuracy of diagnostic tests.


The perfect snowman calculator uses math & science rules to help you design the snowman of your dreams!
Copyright by Omni Calculator sp. z o.o.
Privacy policy & cookies
main background