Someone
public python v1 · immutableclass A(object): i = 1 def print_i(self): print 'In A.print_i() self.i is', self.i # this prints correctlyclass B(A): def vals(self): print 'super(B, self).print_i()', super(B, self).print_i() # The above statement prints correctly. I walk through # it with a debugger, after print_i() returns, but before # this method returns, 'None' is printed. Why?if __name__ == '__main__': b = B() b.vals() print '###'Example output:super(B, self).print_i() In A.print_i() self.i is 1None###