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

Function sort

Exercises/NoModules/Chapter 10/Soln10_06.cpp:49–53  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

47// Sort data in ascending sequence
48template <typename T>
49void sort(std::vector<T>& data)
50{
51 if (!data.empty())
52 sort(data, 0, data.size() - 1);
53}
54
55template <typename T>
56void sort(std::vector<T>& data, size_t start, size_t end)

Callers 1

mainFunction · 0.70

Calls 3

swapFunction · 0.70
emptyMethod · 0.45
sizeMethod · 0.45

Tested by

no test coverage detected