+ 2
What does self do? what is it meant to be? and is it mandatory? What does the __init__ method do? why is it necessary? etc
2 Respostas
+ 1
self is the same as 'this' keyword if you are familiar with java. it mean this object which we are in it.
__init__ is to tell the python interpreter that this folder is a package and should treat accordingly
+ 1
(facepalm) sorry, nope.
self is indeed the current object, but you could name it this, s, t or anything you like. However, the __init__ method tells Python how to instantiate the object and initialize it.