Search⌘ K

Coding Challenge: VAT Calculation

Explore how to write a JavaScript program that asks the user for a raw price, calculates VAT at 20.6%, and outputs the final price. This lesson helps you understand handling user input, variable use, arithmetic operations, and basic type conversions in JavaScript.

Problem statement

Write a program that asks the user for a raw price. After that, it calculates the corresponding final price using a VAT rate of ...