📅  最后修改于: 2022-03-11 14:55:07.541000             🧑  作者: Mango
/*factorial */
DECLARE
x NUMBER(3);
n NUMBER(5):=10;
f NUMBER(10):=1;
BEGIN
FOR x IN 1..n
LOOP
f:= f*x;
END LOOP;
DBMS_OUTPUT.PUT_LINE(f) ;
END;