Questions tagged [currying]

The tag has no usage guidance.

6 questions
Filter by
Sorted by
Tagged with
77 views

Define a curried anonymous function

I want to define a function like f[x_][y_][z_] := x + 2y + 3z but anonymously. The ways to do this that I've discovered so far are (1) define a normal function ...
286 views

Operator currying: how to convert f[a,b][c,d] to {a+c,b+d}?

This question is related to this golfing question (but I'm not interested in golfing, only in functional operator composition): How can we convert f[a,b][c,d] to <...
974 views

Pseudo-currying in one line

Often when I'm writing OOP code using an object-manager association I find myself doing something akin to currying the arguments to some form of delegate object or head. (Building a one-argument ...
296 views

How to use currying to write a tail recursive function for summing factorials given a certain bound

I am very confused about how can i use currying to write a tail recursive function for summing factorials within a certain bound or summing the bounds i.e. given [1,5] i should be getting 1!+2!+3!+4!+...