Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Assignment Part 1 Details Class Design Think of a product that you can buy from a supermarket, like maybe a can of soup or an

Assignment Part 1 Details Class Design
Think of a product that you can buy from a supermarket, like maybe a can of soup or an apple.
Start by listing all the properties of that object that you can think of try to come up with at least ten general
properties of a Product and write these down in your Assignment_Part_1_ Microsoft
Word document.
Next, use the process of abstraction to cut the number of properties back to only four key properties write
these down in the next section of your Word document.
Now, fill in the class diagram for your Product class in the Word document. Your product class does not have
CT701 Programming Fundamentals
Page 2 of 4
to have any methods (i.e. functions) associated with it to perform any actions other than a constructor which
takes and set the four key properties that youve identified.
Next well move on to CheckoutRegister class think about what information the checkout has to keep track
of to allow you to successfully check out of the supermarket. There will only really be three key properties that
the CheckoutRegister cares about, and the CheckoutRegister class should have the following four methods
available:
1) A default constructor that takes no arguments and initialises a new object and its properties,
2) accept_payment(some_amount),
3) scan_item(some_product), and
4) print_receipt().
Fill in the class diagram for the CheckoutRegister class in the Word template, and thatsthe first part completed!

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Driven Web Sites

Authors: Mike Morrison, Joline Morrison

1st Edition

061901556X, 978-0619015565

Students also viewed these Databases questions

Question

4. Support and enliven your speech with effective research

Answered: 1 week ago

Question

3. Choose an appropriate topic and develop it

Answered: 1 week ago