🤖🧑💻 Coding an app in 5min with chatGPT: Engines selling with country tax and quantity discount
🤖🧑💻 Coding an app in 5min with chatGPT: Engines selling with country tax and quantity discount
#chatgpt #basic #prompting #coding
Prompt:
Create a JS/HTML standalone application with a form asking the price, the quantity and the country code (code ISO 2).
This app is for selling car engines, and it should output the total price the seller gives to his customer.
Note that there are some business rules:
First: the tax
If you sell in France(FR) , the tax is zero.
if you sell in Switzerland(CH) , the tax is 31 Euros
for Belgium(BE), it is 35 Euros.
And for Canada(CA) it is 42 Euros.
The second rule is the quantity discount:
If you sell 1 unit, then zero discount.
If you sell between 2 included and 4 included, then there is a discount of 10 %.
If you sell more than 5 (included) units, the discount is 30%.
Okay.
Put the GUI of the form at the top and the result price at the bottom.