Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/uggla/dojo2
Coding dojo #1bis in Rustlang
https://github.com/uggla/dojo2
Last synced: 25 days ago
JSON representation
Coding dojo #1bis in Rustlang
- Host: GitHub
- URL: https://github.com/uggla/dojo2
- Owner: uggla
- License: apache-2.0
- Created: 2024-01-24T09:09:23.000Z (11 months ago)
- Default Branch: main
- Last Pushed: 2024-10-04T19:52:51.000Z (3 months ago)
- Last Synced: 2024-10-14T09:11:07.217Z (2 months ago)
- Language: Rust
- Homepage:
- Size: 473 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Coding Dojo #1bis
## Title: Price Calculation Kata
Goal is to create a module with 2 public fonctions:
- 1 x to calculate the price of items.
- 1 x to covert a price in various currencies.1- Implement the total price calculation based on the following parameters:
- Number of items
- Unit price
- Tax2 - Take into account discounts:
- €1000: 3% discount
- €5000: 5% discount3- Add currency converter:
- 1 € = 2 Krupnic
- 1 € = 3 Zorglub### Examples
Prices:
- Excl. VAT: 3 items at €1.21 each + 0% ⇒ “€3.63”
- Incl. VAT 5%: 3 items at €1.21 each + 5% ⇒ “€3.81”
- Incl. VAT 20%: 3 items at €1.21 each + 20% ⇒ “€4.36”Discounts:
- €1000 → 3% Discount: 5 x €345.00 + 10% tax → “€1840.58”
- €5000 → 5% Discount: 5 x €1299.00 + 10% tax → “€6787.28”Currencies:
- 20€ = 40.00 Krupnic
- 20€ = 60.00 Zorglub## Proposed editor
The idea is to use on online editor. Gitpod seems a good solution in that
case as only a browser is required to edit the code and the workspace can
be shared between participants.
![Edition into Gitpod](pictures/gitpod.png)