Re: curry and compose -- functional language constructs
by Ben Wolfson other posts by this author
May 2 2001 5:17AM messages near this date
Re: curry and compose -- functional language constructs
|
Re: Surprising (for me) benchmark results...
In article <HoNH6.45055$HF.10107141@[...].com> , "Nick
Perkins" <nperkins7@[...].com> wrote:
> I think these are really cool, but i have never seen anyone use curry or
> compose. Why not? Shouldn't everyone use these all the time?
I used a compose() once:
def action_maker(v,r):
vl=(
lambda f: None,
lambda f: sys.stdout.write('removed %s\n' % f)
)
rl=(
lambda f: f,
lambda f: (os.remove(f),f)[1]
)
return compose(vl[v],rl[r])
> Does anyone have any other neat Python solutions that provide
> 'functional-style' features?
There are several memoization modules floating around.
--
Barnabas T. Rumjuggler
"Et tu, Brute?" sedulous.
-- barry in indy, in apihna
--
http://mail.python.org/mailman/listinfo/python-list
Thread:
Nick Perkins
Roman Suzi
Marcin 'Qrczak' Kowalczyk
Alex Martelli
Nick Perkins
Doug Fort
Ben Wolfson
|