Home Segments Top Top Previous Next

219: Practice

Devise a zero-parameter constructor and a three-parameter constructor for the BoxCar class that you were asked to design in Segment 188. The three-parameter constructor is to receive height, width, and length values. Assume reasonable default dimensions for the zero-parameter constructor.