garrettmac
9/15/2017 - 4:14 AM

MEDIUM BLOG POST - Javascript’s 3 Major Paradigms: The Five tenets of Functional Programming [part 3 of 4] Copy Raw

MEDIUM BLOG POST - Javascript’s 3 Major Paradigms: The Five tenets of Functional Programming [part 3 of 4] Copy Raw

function iterativeFactorial(n) {
 let product = 1;
 for (let i = 1; i <= n; i++) {
 product *= i;
 }
 return product;
}