Aw: Re: Aw: Functional style programming in python: what will you talk about if you have an hour on this topic?

Terry Reedy tjreedy at
Mon Jul 18 16:02:54 EDT 2011

On 7/18/2011 8:20 AM, Anthony Kong wrote:
> Thanks for all the great suggestion.
> First of all, Carl is right that it does not take much to impress a
> java programmer about the expressiveness of functional programming.

> Covered map, reduce and filter as Rainer suggested.
> Emphasized the advantages of functional style as summarised by Steve
> D'Aprano.
> I showcased the use of groupby() in itertools. Think about what it
> takes to implement similar logic in Java. Also introduced the gotcha
> of using groupby(): you must first sort the list in the same way you
> want to group them by.
> Then I got ambitious and tried to introduce partial(). I basically
> lost everyone right there. They can understand what partial does but
> do not know why it can be useful. My example was too trivial and it
> did not help. What is the best way to introduce partial/currying?

See my response to Kurian -- Partial Function Application -- just a few
minutes ago.

Terry Jan Reedy

More information about the Python-list mailing list