Le Mon, 27 Apr 2009 22:38:30 +0530,
sudhanshu gautam <sudhanshu9...@gmail.com> s'exprima ainsi:


> Now If I placed the name of the constructor rather than the __init__
> __baba___ so will it also work as a constructor or constructor has specified
> already if yes then give me list of them

Actually __init__ is not the constructor, which is __new__ (much less used), 
but the initialiser. If you try to do their work using other names, it may not 
work as expected because python does some magic in the background. Still, if 
you really know what you're doing it's possible for some of these special 
methods, while not for __new__ I guess. Anyway, it's maybe a bad idea cause 
conventional names help and understand the code.

> ragards
> sudhanshu

Denis
------
la vita e estrany
_______________________________________________
Tutor maillist  -  Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor

Reply via email to