title: How to assign None to object reference in python
body: <p>I am a newbie to python, got little confused over output of following code. </p>
  
  <pre><code>class obj:
      def __init__(self, data):
              self.data = data
  
  o1 = obj(2)
  o2 = o1
  
  def func1(obj):
      obj.data = 5
  
  
  func1(o1)
  print(o1.data)
  print(o2.data)
  o2 = None
  print(o1)
  print(o2)
  </code></pre>
  
  <p>Output:</p>
  
  <pre><code>5
  5
  &lt;__main__.obj instance at 0x7f7f6b5e63f8&gt;
  None
  </code></pre>
  
  <p>Shouldn't o1 object become 'None' too??</p>