I know, this is how it's done in Scheme but it has clearly a more functional approach, whereas Python does rather go the iterative way. Not to mention that explicit is better than implicit in Python.
And yes, I also like the chaining that is possible with jQuery because it consistently returns the changed results.
Yeah this chaining is cool but it is possible with any object programming language. I guess a method returning the objet on which it is when there is no explicit return could help make this a more common thing, but I'm not so sure about this idea.
Anyway you can make jquery in python. I even started doing it.
2
u/nevare Nov 11 '08
Python is also my favorite language and what I miss the most from functionnal programming are
tail call optimisation (I think I heared people didn't wanted it ... but maybe it was just never implemented ?)
more powerfull lambdas
implicit return of the last executed line (it makes you feel you are in a functionnal language)
The last two points are solved in ruby, but they didn't implement tail call optimisation either.