fix: quick_sort_3.cpp warning

This commit is contained in:
David Leal 2022-10-02 21:08:55 +00:00
parent 24f68ea4db
commit d95ac02619

View File

@ -146,7 +146,7 @@ static void test_int() {
}
std::cout << "Test " << num_tests << "\t Array size:" << size << "\t ";
std::vector<int> sorted = sorting::quicksort(arr, 0, size - 1);
std::vector<int> sorted = sorting::quicksort(arr, 0, int32_t(size) - 1);
if (size < 20) {
std::cout << "\t Sorted Array is:\n\t";
std::cout << sorted << "\n";
@ -169,7 +169,7 @@ static void test_double() {
}
std::cout << "Test " << num_tests << "\t Array size:" << size << "\t ";
std::vector<double> sorted = sorting::quicksort(arr, 0, size - 1);
std::vector<double> sorted = sorting::quicksort(arr, 0, int32_t(size) - 1);
if (size < 20) {
std::cout << "\t Sorted Array is:\n\t";
std::cout << sorted << "\n";