On Tue, Feb 16, 2021 at 11:38:33AM -0500, Ned Batchelder wrote:
"lambda" is unnecessarily obscure.
Beginner: "why is it called lambda?"
Teacher: "Don't worry about it, just use it to define a function"
That's a bad answer. A better answer that is more appropriate for nearly everyone is "It's Greek letter, like pi that you may remember from maths class. In some technical computer science, the Greek L, lambda, is used as the symbol for functions." Two sentences, a few seconds to say. At this point the student almost certainly will be either satisfied with the answer, and have learned something new, or will be satisfied with the fact that there is an answer, and promptly forget it because they didn't really care, they just want to know that there is a reason. And for that perhaps one in fifty who go on to ask "Why lambda?", the answer is "They had to choose some letter, and lambda was the one they picked." I don't understand people who are unwilling to explain things. It makes me sad.
I'm not taking a side on whether to change Python, but let's please not lose sight of just how opaque the word "lambda" is. People who know the background of lambda can easily understand using a different word. People who don't know the background are presented with a "magic word" with no meaning. That's not good UI.
You know the approximately 7.4 billion people in the world who aren't native English speakers? And the approximately 5 billion people who speak no English at all? They just said "Welcome to our world!" Honestly, I think this argument about lambda being a magic word is both privileged and silly. Its no more "magic" than tuple, deque, iterator, coroutine, ordinal, modulus, etc, not to mention those ordinary English words with specialised jargon meanings like float, tab, zip, thread, key, promise, trampoline, tree, hash etc. It's just a word. Every single word that we know had "no meaning" to us at some point. None of us were born knowing what "raise" or "hex" means. There is a *ton* of jargon to learn on the way to becoming a decent programmer, I don't know why lambda is singled out for so much hate. Personally I had much more difficulty learning "tuple", or "turple" as I insisted on spelling it for about the first five years. And I still don't know where the word comes from in the first place. Given that it is used in maths, probably Latin, Greek or Arabic. -- Steve