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

Function sort

Examples/Modules/Chapter 08/Ex8_17.cpp:59–63  ·  view source on GitHub ↗

Sort strings in ascending sequence

Source from the content-addressed store, hash-verified

57
58// Sort strings in ascending sequence
59void sort(Words& words)
60{
61 if (!words.empty())
62 sort(words, 0, words.size() - 1);
63}
64
65void sort(Words& words, size_t start, size_t end)
66{

Callers 4

mainFunction · 0.70
mainFunction · 0.50
mainFunction · 0.50
mainFunction · 0.50

Calls 3

swapFunction · 0.70
emptyMethod · 0.45
sizeMethod · 0.45

Tested by

no test coverage detected