Skip to content

halftoone/WildWestStore

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Simple Tax Calculator

Sales Tax Calculator Logic

  • Basic sales tax is applicable at a rate of 10% on all goods, except books, food, and medical products that are exempt.
  • Import duty is an additional sales tax applicable on all imported goods at a rate of 5%, with no exemptions.
  • When you purchase items you receive a receipt, which lists the name of all the items and their price (including tax), finishing with the total cost of the items, and the total amounts of sales taxes paid.
  • The sales tax is rounded up to the nearest 0.05 amounts.

Run the tests

mix test

Sample Input

1	book	at	12.49
1	music	CD	at	14.99
1	chocolate	bar	at	0.85

Sample Output

1	book:	12.49
1	music	CD:	16.49
1	chocolate	bar:	0.85
Sales	Taxes:	1.50
Total:	29.83

About

An Invoice Maker for a store.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages