program Factorial;
var
n, i: integer;
factorial: longint;
begin
writeln('Ingrese un número:');
readln(n);
factorial := 1;
for i := 1 to n do
factorial := factorial * i;
writeln('El factorial de ', n, ' es ', factorial);
end.
Preview:
downloadDownload PNG
downloadDownload JPEG
downloadDownload SVG
Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!
Click to optimize width for Twitter