Why are there leading and trailing underscores in this object constructor?

  oop, python
class C :

def __init__(self,n) :
    # robot name
    self.__name__ = n

def getname(self) :
    return self.__name__

Why are there underscores before and after name?

Source: Python Questions

LEAVE A COMMENT