Runtime comparison of Bubble Sort and Selection Sort algorithm using JavaScript and C++ languages.
git clone https://github.com/VitorHugoAntunes/Algorithm_Execution_Time.git
cd project
npm install OR yarn
What you need to run the tests:
-
Javascript:
NodeJS
andrun code
-
C++:
Have a C++ compiler on your machine: GCC, MinGW, MSVC, Intel C++, Clang LLVM, etc.
Download the <nlohmann/json.hpp> library using VCPKG and add it to your C++ compiler folder. Instructions in this link.
run code
Run tests with different data structures:
- Typescript:
Switch between JSON files from the DATA folder or change the size of the LIST variable with random numbers.
- C++:
Change the typing of the parameters of the BUBBLE SORT or SELECTION SORT algorithms to string or double_t (whichever you want) and choose the JSON file or the array of numbers in the function call.