Forum Discussion
How to display 2-decimal places in variable calculations?
Hi Steve and Holly,
I've been searching the discussions and YouTube clips for a solution to a problem I'm having, and came across this recent one of yours.
I've created a shopping activity for young children. They add fish to a fish bowl and the cost is added as they do so. I've got it all adding and working just as I want it to, except that when the dollars are whole or the cents end in zero, the zeros don't display. So $4.00 will show as 4 (I've put the $ outside the box) and 80 cents will show as 0.8. How can I get the additional zeros (decimal points) to show?
Steve, I've added in the javascript just as you showed to Mel almost 9 years ago (above), and also tried another similar version but without success. I'm sure it's something simple that I'm missing. I'd love it if you could tell me what I'm not doing that I should be.
Thanks so much,
Norah