merits of Lisp vs Python
mystilleef at gmail.com
mystilleef at gmail.com
Wed Dec 13 01:02:37 EST 2006
Paddy wrote:
> Robert Uhl wrote:
>
> > Steven D'Aprano <steve at REMOVE.THIS.cybersource.com.au> writes:
> > >
> > > Speaking as somebody who programmed in FORTH for a while, that doesn't
> > > impress me much. Prefix/postfix notation is, generally speaking, more
> > > of a pain in the rear end than it is worth, even if it saves you a
> > > tiny bit of thought when pasting code.
> >
> > Of course, you use prefix notation all the time in Python:
> >
> > for x in range(0,len(y)):
> > dosomething(x)
>
> In Python, most containers are directly iterable so we are much more
> likely to arrange our program to use:
> for a in y:
> dosomethingwith(a)
>
> -Paddy.
Or the more succinct Python (FP) construct:
map(dosomething, y)
More information about the Python-list
mailing list