Show an alternative diagram for the hierarchy in exercise 8.3 in which the cars are organized first by type (sports car, sedan, SUV, etc.). Show some appropriate variables and method names for at least two of these classes. Compare and contrast the two approaches.
What will be an ideal response?
The hierarchy in exercise 8.3 has the manufacturer information as an inherent part of the inheritance structure, and might store car type information as data in lower level classes. The hierarchy in exercise 8.4 is organized around car type, with the manufacturer as data. Which one would be best depends on the purpose of the system.
You might also like to view...
Provide three sample questions to determine whether a project has operational feasibility.
What will be an ideal response?
Spreadsheet software does not allow you to sort data.
Answer the following statement true (T) or false (F)
_____, a free cloud-based project management tool, runs in a browser window, so there is no software to install to use it.
A. Apptivo B. Smartsheet C. Microsoft Project D. GantterĀ
Why is the performance of a computer so dependent on a range of technologies such as semiconductor, magnetic, optical, chemical, and so on?
What will be an ideal response?