Implementing a Curried Sum Function
Question Link: https://bigfrontend.dev/problem/create-a-sum
Our goal is to achieve the following functionality:
const sum1 = sum(1)
sum1(2) == 3 // true
sum1(3) == 4 // true
sum(1)(2)(3) == 6 // true
sum(5)(-1)(2) == 6 // true
As we see, we need to ...
abshukla.hashnode.dev3 min read