title: What is this dictionary assignment doing?
body: <p>I am learning Python and am trying to use it to perform sentiment analysis. I am following an online tutorial from this link: <a href="http://www.alex-hanna.com/tworkshops/lesson-6-basic-sentiment-analysis/" rel="nofollow">http://www.alex-hanna.com/tworkshops/lesson-6-basic-sentiment-analysis/</a>. I have taken a piece of code as a mapper class, an excerpt of which looks like this:</p>
  
  <pre><code>sentimentDict = {
      'positive': {},
      'negative': {}
  }
  
  def loadSentiment():
      with open('Sentiment/positive_words.txt', 'r') as f:
          for line in f:
              sentimentDict['positive'][line.strip()] = 1
  
      with open('Sentiment/negative_words.txt', 'r') as f:
          for line in f:
              sentimentDict['negative'][line.strip()] = 1
  </code></pre>
  
  <p>Here, I can see that a new dictionary is created with two keys, positive and negative, but no values.    </p>
  
  <p>Following this, two text files are opened and each line is stripped and mapped to the dictionary.  </p>
  
  <p>However, what is the = 1 part for? Why is this required (and if it isn't how could it be removed?)</p>