title: Parse error : bad input on a certain line
body: <p>Open the file <code>romeo.txt</code> and read it line by line. For each line, split the line into a list of words using the <code>split()</code> method. The program should build a list of words. For each word on each line check to see if the word is already in the list and if not append it to the list. When the program completes, sort and print the resulting words in alphabetical order.</p>
  
  <p>I keep getting a parse error <code>bad input on line 7</code> and I don't know why…</p>
  
  <pre><code>fname = input('Enter File Name') 
  fh = open(fname) 
  lst = list()
  for line in fh:
      line = line.rstrip()
      line = line.split()
      for word in line:
          if word in lst: 
              continue
          else : 
              lst.append(word)
  lst.sort()
  print(lst)
  </code></pre>