Skip to content

Instantly share code, notes, and snippets.

@parzibyte
Created February 2, 2019 01:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save parzibyte/70dc596d50a34ced3e960d578f162dbd to your computer and use it in GitHub Desktop.
Save parzibyte/70dc596d50a34ced3e960d578f162dbd to your computer and use it in GitHub Desktop.
/**
Factorial calculado con recursión
en Java
@author parzibyte
*/
public static long factorialRecursivo(long numero) {
if (numero <= 1)
return 1;
return numero * factorialRecursivo(numero - 1);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment