It/210 Checkout Apllication

Topics: Real number, Ring, Vector space Pages: 5 (498 words) Published: May 1, 2012
Associate Program Material
Appendix F

Application-Level Requirements

Application-Level Requirements List

1. The program shall be a basic checkout calculator

2. The program will display a series of screens prompting the user to enter the item name or number, price and quantity.

3. The program will ask to enter any additional items.

4. The program will award a 10% discount if more than four items are purchased of one kind.

5. The program will calculate and display a final tax based on a 7.5% sales tax.

6. The program will calculate and display a subtotal.

7. The program will calculate and display a final total for the items that are purchased.

Input-Process-Output Chart

Complete the following input-process-output chart for the application using a structured programming approach.

Input| Process| Output|
ResponseItemNameOrNumberItemQuantityItemPrice| Get User Input| ItemTotalSubtotalItemQuantityItemPrice| ItemQuantityItemPrice| Calculate Discount Price| Subtotal| Subtotal| Calculate Sales Tax| SubtotalFinalTax|

SubtotalFinalTax| Calculate Totals| FinalTaxSubtotalFinalTotal| FinalTaxSubtotalFinalTotal| Display Total| FinalTaxSubtotalFinalTotal|

Hierarchy Chart

Complete a hierarchy chart for the application by typing into the textboxes below.

Main Module

User Input Module

Calculate Sales Tax Module
Calculate Discount Price Module

Display Total Price Module
Calculate Sales Total Module

Main module
Declare ItemNameOrNumber as String
Declare Response as String
Declare ItemQuantity as Integer
Declare ItemPrice as Real
Declare ItemTotal as Real
Declare Subtotal as Real
Declare FinalTax as Real
Declare FinalTotal as Real
Write “Basic Checkout Calculator”
Write “This program computes sales tax and displays the subtotal.”
Write “and final total.”
Call Get Input Module
Call Calculate Sales Total Module
Call Display Total Price Module
End Main Module
Get Input Module
Write “Would you like to start an order?”
Write “Enter ‘y’ for yes, ‘n’ for no: “
Input Response
Set Subtotal =0
Set ItemTotal=0
Set FinalTax=0
Set FinalTotal =0
While Response = “y”
Write “Please enter item name or number."
Input ItemNameOrNumber
Write "Please enter Item quantity."
Input ItemQuantity
Write "Please enter item price."
Input ItemPrice
If ItemQuantity > 4 then
Set ItemTotal = ItemPrice* ItemQuantity – (ItemPrice * ItemQuantity * 0.10)
Set Subtotal = ItemTotal + Subtotal
Set ItemTotal = ItemPrice * ItemQuantity
Set Subtotal = ItemTotal + Subtotal
End if
Write “Would you like to add another item?”
Write “Enter ‘y’ for yes, ‘n’ for no: “
Input Response
End While
End Get Input Module
Calculate Sales Total Module
FinalTax = Subtotal * 0.075
FinalTotal = Subtotal + FinalTax
End Calculate Sales Total Module
Display Total Price Module
Write “The Final Tax is: + FinalTax
Write “The Subtotal is:” + Subtotal
Write “The total Price is:" + FinalTotal
End Display Total Price Module

ItemTotal ? 0
FinalTax ? 0
FinalTotal ? 0
Subtotal ? 0
"Would you like to
start an order?"
GET Response
"Item Name or Number"
GET ItemNameOrNumber
"Item Quantity"
GET ItemQuantity
"Item price"
GET ItemPrice
>= 4
ItemTotal ? (ItemPrice *
ItemQuantity) - (ItemPrice *
ItemQuantity * 0.10)
ItemTotal ? ItemPrice
* ItemQuantity
"Would you like to add
another item?"
GET Response
Subtotal ? ItemTotal
+ Subtotal
FinalTax ? FinalTax
+ Subtotal * ( .075)
FinalTotal ? Subtotal
+ FinalTax
PUT "the Subtotal is"
PUT "the final tax is" +
PUT "the finalTotal is"
+ FinalTotal¶
Continue Reading

Please join StudyMode to read the full document

You May Also Find These Documents Helpful

  • it 210 Essay
  • Essay about It 210
  • Essay about unit 210
  • Comm 210 Research Paper
  • Dem 210 Essay
  • Hsm 210 Essay
  • LGST 210 Essay
  • It 210 Checkpoint Essay

Become a StudyMode Member

Sign Up - It's Free