Question: Convert the classes and features in Figure Q1 into Java programs. The following questions is to guide you in writing the programs. Create class Choc

Convert the classes and features in Figure Q1 into Java programs. The following questions is to guide you in writing the programs.
- Create class Choc with the given relationship and methods.
- Create class Candy with the given relationship in another .java
- Create class Confectionary with the given relationship, data fields, and methods
- Create class Food with the given methods
MARKS: 40 ng questions and diagram is to guide you on writing a program which perform few calculation, and generat x9 Message Food You have consum $11.2 calories + calculate Calories (double reading): void OK + taste (String d Taste) : void Message Confectionary - calorie : double # flavor : String print) : void + taste (String dTaste) : void Raspberry candy taste nice! OK Message Choc Candy but Orange chocolate taste sweet like you You bring me so much joy print(): void OK Figure Qlia: Class Diagram
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
