- Joined
- Apr 6, 2017
- Posts
- 916
- Solutions
- 119
- Reaction
- 401
- Points
- 488
- Age
- 20
Code:
Start
Scan item barcode
get item name
get item quantity
get item price
Detect if items is taxable
If yes, set tax = o.5*price
If lemonCost == 45
else
lemonCost = 45*quantity
If avocadoCost == 30
else
avocadoCost = 30*quantity
If tamarindCost == 12
else
avocadoCost = 12*quantity
Compute sales tax
Print items and prices to receipt
Calculate subtotal
set subtotal=(sum of prices)
Print subtotal to receipt
Print total sales tax on receipt
Print grand total
set amt=prices+tax
Print receipt
End
Last edited: