We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
Note that JavaScript code snippet is broken, it tryes read data twice (once on hardcoded pard, once on "softcoded"), also it has 2 nested main() functions (which is the reason why output made in inner main() does not work).
To make it work student has to delete everything that is not hardcoded and use arguments "mealCost", "tipPercent" and "taxPercent" in the calculation (do NOT try to readLine() or something, all the data is already read in the hardcoded part).
Day 2: Operators
You are viewing a single comment's thread. Return to all comments →
Note that JavaScript code snippet is broken, it tryes read data twice (once on hardcoded pard, once on "softcoded"), also it has 2 nested main() functions (which is the reason why output made in inner main() does not work).
To make it work student has to delete everything that is not hardcoded and use arguments "mealCost", "tipPercent" and "taxPercent" in the calculation (do NOT try to readLine() or something, all the data is already read in the hardcoded part).