1

I'm learning python and I keep coming across variables like __name__ and __add__. I was wondering if they had a given name (either in the context of Python, or programming in general) and if there exists a resource which defines all of them?

  • 1
    This question seems similar: http://stackoverflow.com/questions/1301346/the-meaning-of-a-single-and-a-double-underscore-before-an-object-name-in-python and covers several aspects of your question, is there something beyond that you need an answer to? – Matt Mar 27 '16 at 23:39

1 Answers1

0

They're call magic methods. This seems to be a decent guide about them: http://www.rafekettler.com/magicmethods.html

willnx
  • 1,253
  • 1
  • 8
  • 14