Using getElementsByClassName is a very old technique that has some issues with it.
I recommend that you use querySelector instead, so that the array index isn’t required either.
var output = document.querySelector(".output");
Using getElementsByClassName is a very old technique that has some issues with it.
I recommend that you use querySelector instead, so that the array index isn’t required either.
var output = document.querySelector(".output");