Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Python: currying

Name: Anonymous 2010-04-29 9:40

Suppose we have an implementation of Python in which functions support currying. We write:


def f(x, y, z):
    print(x, y, z)

f(y=2)(1)(3)


What output will be generated?

Name: Anonymous 2010-04-30 14:33

>>18
while ((c = getchar()) != EOF) is a common idiom in C, and it's useful to be able to do things like a = b = c = 0.
Those two are pretty much the only legitimate uses, though.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List