MCPcopy Create free account
hub / github.com/Apress/beginning-cpp20 / quicksort

Function quicksort

Examples/NoModules/Chapter 11/Ex11_07/math.cpp:94–98  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

92{
93 void quicksort(std::vector<double>& data, size_t start, size_t end);
94 void quicksort(std::vector<double>& data)
95 {
96 if (!data.empty())
97 quicksort(data, 0, data.size() - 1);
98 }
99
100 void quicksort(std::vector<double>& data, size_t start, size_t end)
101 {

Callers 1

medianMethod · 0.70

Calls 3

swapFunction · 0.50
emptyMethod · 0.45
sizeMethod · 0.45

Tested by

no test coverage detected