So you want a calculator to practice some math, but want to capture the results when the calculator is used so you can use them somewhere else in the course.
To create this example, we used the calculator from: https://www.geeksforgeeks.org/javascript/javascript-calculator/. You of course can modify this or use your own.
Once we had this example, we added a few lines of code so that when the user selected = to perform the calculation, those results were saved in a project variable called calculation.










Confirm
Comments ( 0 )
Sign in to join the discussion.