subject
Computers and Technology, 03.04.2020 17:42 amf14

Design a class named Person with fields for holding a person's name, address, and telephone number (all as Strings ). Write a constructor that initializes all of these values, and mutator and accessor methods for every field. Next, design a class named Customer, which inherits from the Person class. The Customer class should have a String field for the customer number and a boolean field indicating whether the customer wishes to be on a mailing list. Write a constructor that initializes these values and the appropriate mutator and accessor methods for the class 's fields. Demonstrate the Customer class in a program that prompts the user to enter values for the customer's name , address, phone number, and customer number, and then asks the user whether or not the customer wants to receive mail. Use this information to create a customer object and then print its information. Put all of your classes in the same file. To do this, do not declare them public. Instead, simply write: class Person { ... } class Customer { ... }

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 23.06.2019 09:30
Name the range function that would generate the following list of integers values: 0,1,2,3,4,5.
Answers: 1
question
Computers and Technology, 24.06.2019 18:00
Your computer running windows 10 is doing some very strange things with the operating system. you are fairly certain it is not a hardware issue. you need to try to get further insight into what is going on within the operating system. which tool would be best-suited for this?
Answers: 1
question
Computers and Technology, 25.06.2019 08:30
What is the chief concern of cloud computing?
Answers: 1
question
Computers and Technology, 25.06.2019 09:00
What do students buy when they pay tuition? o a place to live at a school o the right to attend classes at a school o transportation expenses to attend classes o textbooks
Answers: 2
You know the right answer?
Design a class named Person with fields for holding a person's name, address, and telephone number (...
Questions
question
Mathematics, 24.04.2020 00:23
question
Mathematics, 24.04.2020 00:23
question
Biology, 24.04.2020 00:23
Questions on the website: 13722363