title: List prints square brackets in python 2.7
body: <pre><code>import sys
  import string
  import re
  keywords = []
  task = "*"
  while task not in "ed":
      task = raw_input("Encrypt or Decrypt: \nType ‘e’ to Encrypt\nType ‘d’ to Decrypt\n").lower()
  keyword = "*"
  keyphrase = "*"
  while not(re.match('[a-z ]+$',keyword)):
      keyword = raw_input("enter your first keyword:-").lower()
  while not(re.match('[a-z ]+$',keyphrase)):
      keyphrase = raw_input("enter a key phrase:-").lower()
  
  loop = 0
  repeated_keyword = ""
  if len(keyword) &lt; len(keyphrase):
      while len(repeated_keyword) &lt; len(keyphrase):
          repeated_keyword = repeated_keyword + keyword[loop]
          loop += 1
          if loop &gt;= len(keyword):
              loop = 0
  elif len(keyword) == len(keyphrase):
      repeated_keyword = keyword
      last_charecter_in_keyword = keyword[-1]
  elif len(keyword) &gt; len(keyphrase):
      repeated_keyword = keyword
      last_charecter_in_keyword = keyword[-1]
      while len(repeated_keyword) &gt; len(keyphrase):
          repeated_keyword = repeated_keyword[:-1]    
  
  repeated_keyword_letter_positions = []
  keyphrase_letter_positions = []
  for character in repeated_keyword:
      position_of_char_in_repeated_keyword = (string.ascii_lowercase + " ").find(character) +1
      repeated_keyword_letter_positions.append(position_of_char_in_repeated_keyword)
  for character in keyphrase:
      position_of_char_in_keyphrase = (string.ascii_lowercase + " ").find(character) 
      keyphrase_letter_positions.append(position_of_char_in_keyphrase)
  
  if task == "e":
      final_positions_of_letters = [a + b for a, b in zip(keyphrase_letter_positions,repeated_keyword_letter_positions)]
  elif task == "d":
      final_positions_of_letters = [a - b for a, b in zip(keyphrase_letter_positions,repeated_keyword_letter_positions)]
  new_letter = ""
  
  final_cipher = []
  loop = 0
  alphabet = string.ascii_lowercase + " " + string.ascii_lowercase + " "
  while loop &lt; len(final_positions_of_letters):
      new_letter =alphabet[final_positions_of_letters[loop]]
      final_cipher = str(final_cipher) + str(new_letter)
      loop += 1
  print final_cipher
  </code></pre>
  
  <p>This is a encryption/ decryption programme in python 2.7. However at the end of the programme when the final_cipher list is printed to the shell a pair of [] brackets are printed prior to the contents of the list</p>