"self" vs other names

Courageous jkraska at san.rr.com
Wed Oct 3 02:19:56 CEST 2001


On Thu, 27 Sep 2001 13:20:05 -0700 (PDT), "Sean 'Shaleh' Perry" <shalehperry at home.com>
wrote:

>> 
>> Again, which code reads more easily is a matter of taste.  I just thought
>> I'd mention the possibility.
>> 
>
>not that I subscribe to this, but another common form is simply 's'.  You get
>things like 's.dict' or 's.pid'.

I sometimes use a one letter abbreviation of the object type:

class matrix:

	def f(m):

		pass


C//




More information about the Python-list mailing list