diff --git a/src/ModelingExercise.md b/src/ModelingExercise.md new file mode 100644 index 0000000..8c7f216 --- /dev/null +++ b/src/ModelingExercise.md @@ -0,0 +1,20 @@ +# Exercise + +## Supermarket shopper Class + +| Method | Member variables | Scenario | Result | +|----------------------------------------------|-----------------------------------|---------------------------|-----------------------| +| SumCostOfBasket(HashMap basket) | | | | +| | HashMap basket | Total cost of the items | return the total cost | +| | | | | +| CheckBankBalance() | | I can afford all items | return true | +| | | I cannot afford all items | return false | + + +## Organized individual Class + +| Method | Member variables | Scenario | Result | +|--------------|-----------------------------|------------------------------|--------------------------------| +| GetReciept() | HashMap basket | Purchased items | return list of purchased items | +| | | Quantity of purchased items | return quantity of each item | +| | | Total cost of the basket | return the total cost |