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

Function main

Examples/Modules/Chapter 11/Ex11_06B/Ex11_06B.cpp:6–11  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

4import squaring;
5
6int main()
7{
8 std::cout << "math::sqrt2 has the value " << math::sqrt2 << std::endl;
9 std::cout << "This should be 0: " << (math::sqrt2 - std::numbers::sqrt2) << std::endl;
10 std::cout << "This should be 2: " << math::square(math::sqrt2) << std::endl;
11}

Callers

nothing calls this directly

Calls 1

squareFunction · 0.50

Tested by

no test coverage detected