This commit is contained in:
V0id 2024-03-09 16:08:15 -07:00 committed by GitHub
commit 6475244043
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -3,5 +3,5 @@
* @return {number}
*/
export default function factorialRecursive(number) {
return number > 1 ? number * factorialRecursive(number - 1) : 1;
return number > 1 ? number * factorialRecursive(number - 1) : -1;
}