title: Treating an input (string) as if it was a list in python
body: <p>I have been trying to make a simple code, which reads an input from user. It will check if any of the words from input is a cuss word from a &quot;List&quot; that I created.</p>
  <p>The question here is how can I treat my input (message) the string as if it was a 'List' of words to check if any of them == any word from the &quot;cuss words list&quot; using the &quot;For loop&quot;.</p>
  <p><strong>here's my code:</strong></p>
  <pre><code>input('Enter your message: ')
  Message=str(input)
  cuss_words=['word_1' , 'word_2' , 'word_3']
  
  
  for x in Message:
   if x==[cuss_words]:
    print('You have been banned from chat')
  </code></pre>
  <hr />
  <p>but for some reason after I run it, I don't get the <em>print message</em> even after writing a word from the list.</p>