title: ultimate fixed width Python board array
body: <p>Here again with a proposal and a need;<br>
  as you can know from my previuos question i'm building a simple slot machine script.<br>
  I want five numbers to be printed in a minimal board, the board is 9x9 <code>'[]'</code><br><br>
  like this:<br></p>
  
  <pre><code>[] [] [] [] [] [] [] [] []
  [] [] [] [] [] [] [] [] []
  [] [] [] [] [] [] [] [] []
  [] [] [] [] [] [] [] [] []
  [] [] [] [] [] [] [] [] []
  [] [] [] [] [] [] [] [] []
  [] [] [] [] [] [] [] [] []
  [] [] [] [] [] [] [] [] []
  [] [] [] [] [] [] [] [] []
  </code></pre>
  
  <p>numbers will be printed in center of the grid like this:<br></p>
  
  <pre><code>[] [] [] [] [] [] [] [] []
  [] [] [] [] [] [] [] [] []
  [] [] [] [] [] [] [] [] []
  [] [] [] [] [] [] [] [] []
  [] [] O O O O O [] []
  [] [] [] [] [] [] [] [] []
  [] [] [] [] [] [] [] [] []
  [] [] [] [] [] [] [] [] []
  [] [] [] [] [] [] [] [] []
  </code></pre>
  
  <p>but what i want, like everyone building a board like this one,array is a fixed width string with numbers inside it.<br></p>
  
  <p>the function that print out the entire board is this one:</p>
  
  <pre><code>slot = []
  for row in range(9):
      slot.append(['[]'] * 9)
  
  def print_slot(slot):
      for element in slot:
          print(" ".join(element))
  print_slot(slot)
  </code></pre>
  
  <p>how can i use a format tool like <code>.format</code> if in the second part of my script i will need to acces the list <code>slot</code> at the exact index of every <code>'[]'</code> to do a substitution with numbers?<br></p>
  
  <pre><code>def game_start():
      if start == str(' '):
          first_n = random.randint(0, 9)
          second_n = random.randint(0, 9)
          third_n = random.randint(0, 9)
          fourth_n = random.randint(0, 9)
          fifth_n = random.randint(0, 9)
          slot[4][2] = str(first_n)
          slot[4][3] = str(second_n)
          slot[4][4] = str(third_n)
          slot[4][5] = str(fourth_n)
          slot[4][6] = str(fifth_n)
          print_slot(slot)
  game_start()
  </code></pre>
  
  <p>it's time to build the array for the ultimate fixed width board for everyone in need of it!</p>
  
  <pre><code>:-)
  </code></pre>