[Python-ideas] Syntactic sugar to declare partial functions

Chris Angelico rosuav at gmail.com
Mon Aug 13 23:59:50 EDT 2018


On Tue, Aug 14, 2018 at 7:58 AM, Greg Ewing <greg.ewing at canterbury.ac.nz> wrote:
> Chris Angelico wrote:
>>
>> No, lambda calculus isn't on par with brakes - but anonymous functions
>> are, and if they're called "lambda", you just learn that.
>
>
> It's like saying that people would find it easier to learn to
> drive if "brakes" were called "stoppers" or something. I don't
> think that's true.

Reminds me of this:

"So, there's some buttons on the floor. Pedals. Uhh.... That's the
"go" pedal... That, I believe, is the stopper... and this... this
doesn't do anything...."
-- Wreck It Ralph, trying to figure a car out.

I'm pretty certain he didn't do any better that way than if he'd used
words like "accelerator" and "brake". In fact, this supports my
assertion that it's not the terminology that bites you - it's the
concepts behind it. Even if he'd known that the other pedal was called
the "clutch", it wouldn't have helped him much without knowing how to
use it...

Whether you spell it "function(arg) {...}" or "lambda arg: ...", it's
the semantics that are hardest to learn.

ChrisA


More information about the Python-ideas mailing list