← Back to companies
[ OK ] Loaded —
[ INFO ]
$ cd
$ ls -lt
01
02
03
04
05
$ ls -lt
01
02
03
04
05
user@intervues:~/$
Implement a curry function that takes a function fn as an argument and returns a curried version of that function. A curried function can be invoked with any number of arguments. If the number of arguments provided is less than the number of parameters expected by the original function, the curried function should return a new function that accepts the remaining arguments. Once enough arguments have been supplied, the original function should be called with all the accumulated arguments. The curried function should also preserve the this context of the original function.