Testing 5 different sorting algorithms using the time taken, amount of swaps occured and number of comparisons to sort arrays of different sizes in their best, worst and average case.
- Bubble Sort
- Selection Sort
- Insertion Sort
- Merge Sort
- Quick Sort
When the array is already sorted.
When the array is already sorted in the opposite order of which it is supposed to be sorted by the algorithm.
When the array elements are in random order.
To clone, build and run this project you need:
- git version 1.7.10
- G++ compiler
- cmake 3.31.6
- python3
git clone https://github.com/JestiferHarold/sorting_benchmark_cppcd sorting_benchmark_cpp
cmake -S . -B <any folder name prefereably build>
cmake --build <folder name>
<folder name>/debug/testpython -m venv venvfor linux
source venv/bin/activate for windows
.\venv\Scripts\Activate.bat //for windowspip install -r requirements.txtpython main.py

