Clear function | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

Clear function

I'd like my reset function to also reset my output area with the id "result" inside id "resbox". Can someone send a working code? Thank you https://code.sololearn.com/WTFyM95eGJw6/?ref=app https://code.sololearn.com/WTFyM95eGJw6/?ref=app https://code.sololearn.com/WTFyM95eGJw6/?ref=app

22nd Jul 2020, 12:10 PM
Stefan
Stefan - avatar
1 Answer
+ 3
you would just make a reset() function put in it output = document.getElementById(“result”) output.innerHTML = “” just as you did when you calculated the result
22nd Jul 2020, 12:17 PM
Reece
Reece - avatar