I want to implement an arrow function which is equivalent to another normal function works like the following example:
f(h)(a1)(a2)...(an)
works like h(a1, a2, ..., an)
.
I think I have to implement it with the following psuedocode, but I don't know how can I find out what is the number of h function arguments?
pseudocode:
function h (...varArgs) {
}
var f = (h) => {
return ...
}