I am currently studying Python and I have seen in many source codes that uses init(self) but I do not know about it.
I'm a newbie so please explain it easily.
self is like the 'this' keyword in JavaScript. If you have
def __init__(self):
self.foo = 'bar'
that object will now have a .foo that is equal to a string of bar.
Passing self in elsewhere is used too. If you want your object to have a method
def myMethod(self, parameter1, parameter2):
#do stuff
self is needed so that the method is attached to the created objects