Skip to content

java coding problem - calculate the sales tax for different products

Notifications You must be signed in to change notification settings

adolfov/salestax

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

salestax

java coding problem - calculate the sales tax for different products

how to run

./mvnw spring-boot:run

how to test

sample request 1:

{
 "items": [
  {
   "quantity": 1,
   "product": {
     "name": "book",
     "price": 12.49,
     "exempt": true
    }
  },
  {
   "quantity": 1,
   "product": {
     "name": "music CD",
     "price": 14.99
    }
  },
  {
   "quantity": 1,
   "product": {
     "name": "book",
     "price": 0.85,
     "exempt": true
    }
  }
 ]
}

sample request 2:

{
 "items": [
  {
   "quantity": 1,
   "product": {
     "name": "box of chocolates",
     "price": 10.00,
     "exempt": true,
     "imported": true
    }
  },
  {
   "quantity": 1,
   "product": {
     "name": "bottle of perfume",
     "price": 47.50,
     "imported": true
    }
  }
 ]
}

About

java coding problem - calculate the sales tax for different products

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published