Question

Create a program in python based on incremental development processes of collecting user requirements, designing, coding,...

Create a program in python based on incremental development processes of collecting user requirements, designing, coding, testing and debugging to implement the following functionalities of a shopping cart:

• The users can add as many items they wish

. • A digital calculator to calculate the amount of all the items in the cart at any point of time

. • Should be able to remove some or all items from the cart depending on the available budget.

a. Specify the user requirements and suitable assumptions made.

b. Design a ShoppingCart class diagram using the UML notation that matches the specifications.

Homework Answers

Answer #1

a.) User Requirements for Shopping Cart:

  1. The shopping cart function should display all the product descriptions added by user to the shopping cart.
  2. While displaying the product, it should get the product availability from inventory system and product price from pricing system to display the availability and pricing information.
  3. It should allow the user to check out the product(s) in shopping cart.
  4. The digital calculator must be able to calculate the price of all items in the cart.

Assumptions:

  1. User had already logged in.
  2. User had selected non-zero products from search operation.

b.) UML Diagram for ShoppingCart class:

ShoppingCart

-CartID:String

-DateCreated:Date

-DateModified:Date

-Price:Number

+additem(item)

+removeitem(item)

+updateQuantity(item, quantity)

+calculateTotalPrice(cart):Number

  

Know the answer?
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for?
Ask your own homework help question
Similar Questions
ADVERTISEMENT
Need Online Homework Help?

Get Answers For Free
Most questions answered within 1 hours.

Ask a Question
ADVERTISEMENT