javascript for in loop returning undefinded
问题 Looking for help with a for in loop I am using in which returns undefined at the the end. I have 26 buttons, one button for each letter in the alphabet. I need to scan through the buttons so that when a button is clicked I get the value of that button. I'm using a class search which returns a node of all the buttons. On doing a console log this returns 26 buttons, which i would expect. I then set up the for in loop to run through the buttons to add the o'clock to each, at the end of running