Complete the interactive program

Assignment Help Programming Languages
Reference no: EM132378490

Assignment -

Assessment Information - In this assessment, you are required to complete the interactive program to be installed in a stamp-selling machine in Post Office. This machine sells postage stamps for two types of items (letter and parcel).

Software inputs and output -

Inputs into your program will include:

  • The price guides (as csv files) for letter and parcel - Economy Letters Price Guide ($).csv and Economy Parcel Price Guide_by Sea ($).csv
  • The country-zone mapping csv file - ? Countries and Zones.csv

Each of these price guides will contain the price information for the postage type upon different item weights and destination zones. Note that these files should be loaded in a proper data structure when your software starts.

The details of the items to be posted provided by users, including type (letter or parcel), weight, destination countries, quantities etc. You will need to design a clear and interactive way to acquire inputs from users.

The pre-stored sales history. You will be given a pre-stored sales history file "sales_history.csv", which contains the history of stamp sales. Please refer to the section of Functional requirements regarding the format & description of this file.

Outputs from your program include:

Upon each customer completed his/her shopping, your program will need to:

  • save the invoice along with the list of purchased stamps into a .txt file (refer to the section of Functional requirements).
  • append the purchased items to the sales record "sales_history.csv" (refer to the section of Functional requirements).

Information and guidance to navigate and assist users during shopping.

Functional requirements -

Your program should support continuous shopping activities in Post Office. If you demand the next user to restart the program each time they do shopping, your program does not fulfill this requirement. However, you could assume that it serves only one customer at a time, i.e., the next customer will only start shopping after the previous customer checkouts or cancel his/her shopping.

This program should provide the following functionalities as a stamp-selling machine.

[Fun 1] Add an item to the shopping cart

Your program should allow the user to add items to his/her shopping cart. You will need to design an interactive way to acquire details of each item that he or she wants to purchase (such as type of post, e.g., letter or parcel, its weight, destination country, etc.).

[Challenge point] Available methods and pricing information

You will need to provide proper guidance for customers during their shopping experience. For example, once a customer submits the detail of a parcel, e.g., weight, destination country, you should let know the available methods that they can choose (e.g., letter or parcel, etc.) and the associated pricing.

[Challenge point] Checking duplicate item entry

If a user tries to add a duplicate item into the shopping cart, your program should prompt the user to confirm whether or not he/she wants to continue this action.

[Fun 2] View shopping cart

Users should be able to view their shopping cart. Once requested, your program should print out the list of items & costs, as well as the total cost of the items in the shopping cart.

[Fun 3] Amend an item

Your program should allow the user to amend an item in the shopping cart, limited to its weight only.

[Fun 4] Remove an item from the shopping cart

Your program should allow the user to delete an item in the shopping cart. It should ask the users to confirm the deletion before removing an item from the cart.

[Fun 5] Checkout

Once a customer chooses to check out, the program should print out the invoice along with a list of purchased stamps to a .txt file. This file should have a unique name, indicating the shopping date and time (see the example in the following figure). It is assumed that the list of stamps can be divided and used by the users in their post items. Then, staff in Post Office can check the stamps and arrange the delivery. The format of the invoice should look like the figure (see attached file).

Then, your program will also need to add the record to the given "sales_history.csv" file. Each record contains the information for each sold item:

Field

Description

sale_id

this is a unique identifier for a sale record. You can choose to use an incremental key for the sale_id, e.g., the id for the current sale = the id of the previous sale + 1.

Note that a sale only occurs when a customer successfully checks out. A sale (to a customer) could contain multiple stamp items, but they are of the same sale_id.

date_time

date & time of the purchased in yyyy-mm-dd hh:mm:ss? format

weight

The weight of the item (in kg)

destination country

The destination country of where the item will be sent to

item type

The type of item is one of the following values: letter or parcel.

cost

The cost of the item

Note that you should not change the name and format of this file.

Exception handling - Your program should try to avoid or catch any kinds of exceptions and errors, so the execution won't be interrupted and it won't enter abnormal states.

When handling exceptions related to user inputs, your system should return meaningful error messages so that the users can correct their inputs.

Examples of these errors are (but not limited to):

  • User input errors, e.g., option entered is invalid, invalid country name, invalid weight, etc.
  • If the shopping cart to be paid has zero cost, etc.

Documentation - Precise and concise comments/documents of your code are essential as part of assessment criteria. Do Not include things that are irrelevant in your code as that will reduce your code readability.

Note - Require the code to be well organised and easy to read. Commenting is thorough as well as concise. Need documentation to provide clear, concise and thoughtful reflections on the process of developing the code. Well commented code.

Attachment:- Assignment File.rar

Reference no: EM132378490

Questions Cloud

Advantages and disadvantages of having formalized : What are some of the advantages and disadvantages of having formalized procedures for improving the effectiveness or efficiency of innovation?
MITS5501 Software Engineering Methodology Assignment Problem : MITS5501 Software Engineering Methodology Assignment help and solution, Victorian institute of technology, Assessment help - Case Study Assignment
Outline recruitment process for all hr recruiters : You lead a team of two HR Generalists and three HR Recruiters. It is your job to outline recruitment process for all HR Recruiters and Generalists on your team
Business combinations can be domestic or international : In a global world, business combinations can be domestic or international. Be sure to mention which rate you choose in the subject line.
Complete the interactive program : In this assessment, you are required to complete the interactive program to be installed in a stamp-selling machine in Post Office
By how much did owners equity increase or decrease : If during the year total assets increase by $83000 and total liabilities decrease by $20000 by how much did owners equity increase/ decrease.
How technology can help with internal control monitoring : You are the internal audit manager for Peak Corporation. You have been asked to explain to the CEO how technology can help with internal control monitoring.
What countrys department of the ministry of finance : What country's Department of the Ministry of Finance recommended that IFRS be adopted and why? The response paper should be in APA format.
Evaluate integrity of a prospective clients key executives : Do the profession's technical standards explicitly require auditors to evaluate the integrity of a prospective client's key executives?

Reviews

len2378490

9/29/2019 10:17:57 PM

Require the code to be well organised and easy to read. Commenting is thorough as well as concise. Need documentation to provide clear, concise and thoughtful reflections on the process of developing the code. Well commented code. Submission - Rename “rename_me” directory to your student ID. This directory should contain stamp_selling.ipynb, input CSV files, sales_history.csv, and sales invoices. Write all the code and documentation in stamp_selling.ipynb. Do not include any unnecessary file in this folder. Zip the containing folder with the same name. Penalties - Late submission: -5% per day late, no submission accepted after 4 days.

Write a Review

Programming Languages Questions & Answers

  Non-negative positions in positions

Write a predicate pick(+From, +Positions, -Picked) that unifies Picked with an atom consisting of the characters in From at the zero-based, non-negative positions in Positions.

  Hubspot: inbound marketing and web 2.0

Hubspot: Inbound Marketing and Web 2.0

  Give the pseudocode for the enqueue

Show how to implement a queue using two stacks S1 and S2 so that the amortized cost of each operation on the queue is O(1).

  Write the necessary function in a tail-recursive manner

CS 341 Programming Languages Assignment - four small F# functions. Write the necessary function in a tail-recursive manner. Test using F# interactive

  Create project to compute checking account balance

Create a project to compute your checking account balance. Form: Include radio buttons to indicate the type of transaction: deposit, check, or service charge.

  Analyze average-case performance of linear search algorithm

Analyze the average-case performance of the linear search algorithm, if exactly half the time the element x is not in the list.

  Run the application

Running the application. Select Debug > Start Debugging to run your application. Test your application by checking one or more of the new services.

  Write driver class to instantiates-updates flight objects

Write a driver class called FlightTest whose main method instantiates and updates several Flight objects. Two classes are needed for this project: Flight and FlightTest.

  Matlab that will use the flipping of two-sided coins to sim

Write a program in matlab that will use the flipping of two-sided coins to simulate any event that has a probability of success(Ps) that ranges between 0 and 1. The simulation will most likely be approximate. It must be accurate to at least 0.01

  Simulate the deposits made to a fictitious bank account

In this programming assignment you will simulate the deposits and withdrawals made to a fictitious bank account. In this case synchronized threads will make the deposits and withdrawals.

  Write sql statements

Write a SQL statement to display the Major of students with no duplications. Do not display student names.

  What other techniques could be used outside of recursion

If the call CountDown(0)was issued, what would be the output of the CountDown routine? What other techniques could be used outside of recursion? What is the benefit of using recursion

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd