About the method parameters
We have seen during defining a function that the parameters are written inside the parenthesis.
And here the definition of method is written that the object is one of its parameters , from above we can conclude that object should be written inside the parenthesis of method but the method syntax in python is given as object.method(). It is contradicting the definition of method.
Please help me regarding this.
Thanks for reaching out.
Both could be used, depending on the situation. Some objects have methods and you can use them and some methods accept as a parameter object and then we can make some modifications of the object in the method.
Hope this helps.