Created
November 13, 2014 02:25
-
-
Save leopic/84ae5f74f927cfac4836 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CREATE OR REPLACE FUNCTION factorial(numero IN NUMBER) | |
RETURN NUMBER | |
IS resultado NUMBER := 1; | |
BEGIN | |
FOR num IN 1..numero LOOP | |
resultado := resultado * num; | |
END LOOP; | |
RETURN (resultado); | |
END; | |
/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment