We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent cee6cd8 commit 8e24946Copy full SHA for 8e24946
JavaScript/4-factorial.js
@@ -2,7 +2,7 @@
2
3
const factorial = (n) => {
4
if (n === 0) return 1;
5
- else return n * factorial(n - 1);
+ return n * factorial(n - 1);
6
};
7
8
console.log(factorial(10));
0 commit comments