title: Python and matrix, move columns & rows
body: <p>I have a little issue with my python script.</p>
  
  <p>Actually, I'm working on real led matrix 8x8 and I want to draw a text with animation (right to left, left to right, up to down, down to up).</p>
  
  <p>For example, I want to write the E letter. So I created the E matrix:</p>
  
  <pre><code>matrix =[
  "1","1","1","1","1","1","1","1",
  "1","1","1","1","1","1","1","1",
  "1","1","0","0","0","0","0","0",
  "1","1","1","1","1","0","0","0",
  "1","1","1","1","1","0","0","0",
  "1","1","0","0","0","0","0","0",
  "1","1","1","1","1","1","1","1",
  "1","1","1","1","1","1","1","1"]
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/zICy1.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/zICy1.png" alt="Like this"></a></p>
  
  <p>But now, imagine I want to move my E to make animation. If I move my E to the left, the eighth column will be empty, and after 1s, the seventh too etc...
  And when my matrix will be completely empty, my E letter will start in right position again... </p>
  
  <p>Do you have an idea how can I do that with array, matrix or whatever?</p>
  
  <p>Thank you</p>
  
  <p>EDIT, code test with <a href="https://www.jdoodle.com/python3-programming-online" rel="nofollow noreferrer">https://www.jdoodle.com/python3-programming-online</a>:</p>
  
  <pre><code>matrix = [  [0, 0, 0, 1, 0], 
              [0, 0, 0, 1, 0],
              [0, 0, 0, 1, 0], 
              [0, 0, 0, 1, 0], 
              [0, 0, 0, 1, 0]]
  
  print(matrix)
  
  def shift(my2dArray):
      for _ in range(5): # shift to the left 8 times - brute force
          for row in my2dArray:
              row.pop(0) # removes first element of each row
              row.append("0") # add "0" to the end of the row
          # code to update display here and sleep for a bit
  
  shift(matrix)
  
  print(matrix)
  </code></pre>