2021-06-29 20:01:58 +02:00
|
|
|
# sorting-algorithms
|
|
|
|
|
2023-07-02 17:28:54 +02:00
|
|
|
Created by [@theoludwig](https://github.com/theoludwig) on 29 June 2021.
|
2021-06-29 20:01:58 +02:00
|
|
|
|
|
|
|
## Instructions
|
|
|
|
|
|
|
|
In computer science, a sorting algorithm is an algorithm that puts elements of a list in a certain order.
|
|
|
|
We will use the [numerical order](https://en.wikipedia.org/wiki/Numerical_order).
|
|
|
|
|
|
|
|
Write a function that takes a list of integers and sort them in ascending order.
|
|
|
|
|
2021-06-29 22:38:17 +02:00
|
|
|
## Input
|
|
|
|
|
2023-08-27 15:09:31 +02:00
|
|
|
- **Line 1:** An integer $n$ for the length of the list of integers
|
|
|
|
- **$n$ next lines:** the numbers to sort
|
2021-06-29 22:38:17 +02:00
|
|
|
|
2021-06-29 22:02:52 +02:00
|
|
|
### Constraints
|
|
|
|
|
2023-08-27 15:09:31 +02:00
|
|
|
- $$n \leq 25 000$$
|
2021-06-29 22:02:52 +02:00
|
|
|
|
2021-06-29 20:01:58 +02:00
|
|
|
## Source
|
|
|
|
|
2023-08-21 23:11:08 +02:00
|
|
|
[Wikipedia - Sorting algorithm](https://en.wikipedia.org/wiki/Sorting_algorithm)
|
2021-06-29 20:01:58 +02:00
|
|
|
|
|
|
|
## Examples
|
|
|
|
|
|
|
|
See the `test` folder for examples of input/output.
|