[Tutor] a quetion on "There should be one and preferabley one obvious way to do it"

Karthik Gurumurthy karthikg@aztec.soft.net
Mon, 21 Jan 2002 14:03:55 +0530


hi all,

this is what i read @ bruce eckel's python site.
He says this is against Perl's "there is more than one way to do it"

Let me point out that i'm not asking about languages comparisons here !
So am not interested in Perl's way of doing things!

For example,

map(None,l1,l2)

does the same thing as
say

zip(l1,l2)

+
there are more ways of doin it

dict.has_key(key)
is same as
if key in dict

We have list comprehensions that work like maps

So here too we have different ways of getting something done.
I guess i have not been able to get a clear picture of this python
philosophy.
any inputs?

thanks,
karthik.