Re: Tcl/Lisp/Python: A "User" point of view

Mark Friedman (bobo@avogadro.arc.nasa.gov)
Tue, 27 Sep 1994 16:36:05 GMT

In article <1994Sep27.085636.23932@paramount.nikhefk.nikhef.nl>
templon@paramount.nikhefk.nikhef.nl (Jeffrey Templon) writes:

If you want to choose a language which will really get used by a
wide spectrum of people, I think Python is a good choice. I see
people like me using it, and I also see computer science people
posting parser generators written in Python. It seems that this
language has enough flexibility and "dynamic range" to reach a
large class of users.

I was recently surfing through the net and saw that among the new
features of the language Python was support for functional
programming. I clicked and saw the following:

Lambda Forms
============

By popular demand, a few features commonly found in functional
programming languages and Lisp have been added to Python. With the
lambda keyword, small anonymous functions can be created. Here's a
function that returns the sum of its two arguments:

lambda a, b: a+b.

Lambda forms can be used wherever function objects are
required. They are syntactically restricted to a single
expression. Semantically, they are just syntactic sugar for a
normal function definition. Like nested function definitions,
lambda forms cannot reference variables from the containing scope,
but this can be overcome through the judicious use of default
argument values, e.g.

def make_incrementor(n):
return lambda(x, incr=n): x+incr

A few clicks later I also saw the following:

Note that functions created with lambda forms cannot contain
statements.

Supposedly these features were created by popular demand. So which one
of you demanded these eviscerated lambdas?

-Mark

-- 
Mark Friedman
NASA-Ames Research Center
MS 269-2
Moffett Field, CA 94035-1000

vmail: (415) 604-0573 email: bobo@ptolemy.arc.nasa.gov