Skip to content

Instantly share code, notes, and snippets.

@ukstudio
Created November 1, 2009 19:45
Show Gist options
  • Select an option

  • Save ukstudio/223679 to your computer and use it in GitHub Desktop.

Select an option

Save ukstudio/223679 to your computer and use it in GitHub Desktop.
class Sample:
def __private_method(self):
print "private"
return None
sample = Sample()
# sample.__private_method()
# AttributeError
sample._Sample__private_method()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment