Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/Apress/beginning-cpp20
/ power
Function
power
Examples/NoModules/Appendix A/ExA_09/Power.cpp:12–16 ·
view source on GitHub ↗
Source
from the content-addressed store, hash-verified
10
}
11
12
double power(double x, int n) // power() has external linkage
13
{
14
return n >= 0 ? localHelper(x, static_cast<unsigned>(n))
15
: 1.0 / localHelper(x, static_cast<unsigned>(-n));
16
}
Callers
1
main
Function · 0.70
Calls
1
localHelper
Function · 0.70
Tested by
no test coverage detected