One of the major differences between functions and methods in Python is the first argument in the method definition. Conventionally, this is named self. The user can use different names as well, but self is used by almost all the developers working in Python. We will also be using this convention for ease of understanding.
This pseudo-variable provides a reference to the calling object, that is the object to which the method or property belongs to. If the user does not mention the self as the first argument, the first parameter will be treated for reference to the object.
Note: The self argument only needs to be passed in the method definition and not when the method is called.
Given below is an example of implementing methods in a class: