title: a[1:-1] vs a[1:len(a)] in Python
body: <p>I was working on the PygLatin exercise on Codeacademy and one point of the exercise asked you to slice the variable so that it contained everything but the first element. The suggested method was to use <code>a = a[1:len(a)]</code>, I however tried to use <code>a = a[1:-1]</code>, but it failed. It went to the second last element but not the last (eg for the input <code>justin</code>, it outputted <code>ustinja</code> instead of <code>ustinjay</code>). As I understand it <code>-1</code> represents the last element in the list, so I was wondering why this method did not work. </p>
  
  <p>Here is the code I wrote:</p>
  
  <pre><code>    pyg = 'ay'
  
      original = raw_input('Enter a word:')
  
      if len(original) &gt; 0 and original.isalpha():
          word = original.lower()
          first = word[0]
          new_word = word + first + pyg
          # new_word = new_word[1:-1] # this line did not work
          new_word = new_word[1:len(new_word)] # this line did work
      else:
           print 'empty'
  </code></pre>