#include #include "thing.h" using namespace std; // member functions Thing::Thing() : LIMIT(20) // <-- initialization of const member // default to "empty" thing { height = 0; weight = 0; cout << SIZE; cout << "LIMIT = " << LIMIT << '\n'; } Thing::Thing(int h, int w) : LIMIT( h ) // <--- initialization of const // constructor to initialize memeber data to h, w { height = h; weight = w; if (height > LIMIT) height = LIMIT; cout << "LIMIT = " << LIMIT << '\n'; } void Thing::Show() const { cout << "Height = " << height << "\t\tWeight = " << weight << '\n'; } void Thing::Set(int h, int w) { height = h; weight = w; if (height > LIMIT) height = LIMIT; } int Thing::GetHeight() const { return height; } int Thing::GetWeight() const { return weight; }