title: Create a table of buttons in Javascript
body: <p>I am new to javascript and I need to make a black jack style game. I need to create a table of replicated buttons in a 6x6 row(36 buttons total). They will display an x unless pressed and then they will generate a random number 1 to 9 and add it to a total score in a global variable. If the buttons clicked put you over 21 then you lose but if you get a score of exactly 21 you will win the game and a pop up message will prompt the user of their win. </p>
  
  <p>I not sure how to make a table and then replicate the buttons. I also would like to know how to change the value of the button from x to a random number. </p>
  
  <p>The game will look something like this.</p>
  
  <p><img src="https://i.stack.imgur.com/FRw4t.png" alt="Black Jack Style Game"> </p>
  
  <p>I am not asking for the full game to be done for me I just want to know how to replicate buttons in a table, point them all to the same function, and change the value displayed on the button when one is clicked. If you can show me an example of anyone of those concepts I would greatly appreciate it. </p>