Multiple Choice
Regarding the invoice-printing application from section 12.3, it is decided that a Customer class is needed to store customer information, including the name, billing address, and a customer id number to be printed at the top of each invoice. Since the existing Address class already stores the customer's name and physical address, the new Customer class can simply reuse Address. Select the code segment that best illustrates how the Customer class can reuse the existing Address class. public class Customer ___________________________
A) extends Address
{
Private String idNumber;
…
}
B) {
Private Address information;
Private String idNumber;
…
}
C) implements Address
{
Private String idNumber;
…
}
D) {
Private Address information;
Private String name;
Private String street;
Private String city;
Private String state;
Private String zip;
Private String idNumber;
…
}
Correct Answer:

Verified
Correct Answer:
Verified
Q7: The textbook recommends a five-part program development
Q8: You are designing a software solution for
Q28: During the implementation phase, which of the
Q43: How does a UML diagram denote classes
Q66: A UML class diagram would be most
Q96: Which of the followings statements about class
Q99: In general, you need _ when an
Q100: If you have parallel arrays or array
Q101: Which of the following statements about class
Q103: Consider the following code snippet: public class