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

Method Box

Examples/NoModules/Chapter 12/Ex12_05A/Ex12_05A.cpp:10–10  ·  view source on GitHub ↗

Constructor for a cube (explicit!)

Source from the content-addressed store, hash-verified

8 Box(double length, double width, double height);
9 explicit Box(double side); // Constructor for a cube (explicit!)
10 Box() = default; // Defaulted default constructor
11 Box(const Box& box); // Copy constructor
12
13 double volume(); // Function to calculate the volume of a box

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected