Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/Apress/beginning-cpp20
/ countWords
Function
countWords
Exercises/Modules/Chapter 20/Soln20_13/Soln20_13.cpp:121–127 ·
view source on GitHub ↗
Source
from the content-addressed store, hash-verified
119
}
120
121
WordCounts countWords(const Words& words)
122
{
123
WordCounts result;
124
for (auto& word : words)
125
++result[word];
126
return result;
127
}
128
129
void showWordCounts(const WordCounts& wordCounts)
130
{
Callers
1
main
Function · 0.70
Calls
no outgoing calls
Tested by
no test coverage detected