Java objected oriented programming, create Candle class and its subclasses
Not what you're looking for?
First I'm new to java oop and i need help here's the problem Mick's Wicks makes candles in various sizes. Create a class for the business named Candle that contains data fields for color, height, and price. Create get methods for all three fields. Create set methods for color and height, but not for price. Instead, when height is set, determine the price as $2 per inch. Create a child class named ScentedCandle that contains an additional data field named scent and methods to get and set it. In the child class, override the parent's setHeight() method to set the price of a ScentedCandle object at $3 per inch. Write an application that instantiates an object of each type and displays the details. Save the files as Candle.java, ScentedCandle.java, and DemoCandles.java.
Purchase this Solution
Solution Summary
Java objected oriented programming, create Candle class and its subclasses
Purchase this Solution
Free BrainMass Quizzes
C# variables and classes
This quiz contains questions about C# classes and variables.
Excel Introductory Quiz
This quiz tests your knowledge of basics of MS-Excel.
C++ Operators
This quiz tests a student's knowledge about C++ operators.
Javscript Basics
Quiz on basics of javascript programming language.
Basic Computer Terms
We use many basic terms like bit, pixel in our usual conversations about computers. Are we aware of what these mean? This little quiz is an attempt towards discovering that.