title: Delete last characters of a series of strings
body: <p>Say I have an array of thousands of colours:</p>
  
  <pre><code>x=[blue, red, green,...]
  </code></pre>
  
  <p>How do I delete the last character(s) of each string so x1 would be [blu, re, gree,...]</p>
  
  <p>I tried this:</p>
  
  <pre><code>x1=[]
  for i in range (0,len(x)):
      x1[i]=x[i:-1]
  </code></pre>
  
  <p>The error I get is: list assignment index out of range</p>
  
  <p>Any idea how to do this?</p>