Question: java programming code 1. Create the class product: a. Create the constructor, getters and setters. b. Write to string method to print the information for
java programming code

1. Create the class product: a. Create the constructor, getters and setters. b. Write to string method to print the information for the product. c. Write a method to return how much we pay for the product: Examples: Milk: 3000.200 Banana: 2000.450 2. Create the class discount product: a. Create the constructor, getters and setters. b. Write to string method to print the information for the discount product. c. Write a method to return how much we pay for the discount product: Milk: (3000.200)(10.3) 3. Create the class fruit product: a. Create the constructor, getters and setters. b. Write to string method to print the information for the fruit product. c. Write a method to return how much we pay for the fruit product: Banana: (2000.450)5 4. Create the main class: a. Create two objects one for discount product and another for fruit product. b. Use the to string method to print the two objects information
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
