I have a doubt.... What if the 'other' would have been declared in '__init__' ? Was it a problem...? Help wouls be apreciated | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

I have a doubt.... What if the 'other' would have been declared in '__init__' ? Was it a problem...? Help wouls be apreciated

HELP NEEDED

26th Jun 2017, 7:35 PM
Bluebird
Bluebird - avatar
3 Answers
+ 5
No, using "self" is just a convention, you can as well use "other" or any other non-keyword name. Will work the same.
27th Jun 2017, 9:17 PM
Kuba Siekierzyński
Kuba Siekierzyński - avatar
+ 1
No change will happen both self and other are just names given to the parameters as Kuba said :)
29th Jun 2017, 10:42 AM
S.Naveen Kumar
S.Naveen Kumar - avatar
0
Ok... So what if i use 'other' keyword in '__init__' constructor?
27th Jun 2017, 10:13 PM
Bluebird
Bluebird - avatar