June 2018 Update

This commit is contained in:
Ingy döt Net 2018-06-22 20:57:24 +00:00
parent ba8067c3b7
commit 22f33d4004
5278 changed files with 84726 additions and 14379 deletions

View file

@ -1,14 +1,15 @@
begin
integer procedure factorial( n );
integer procedure factorial(n);
integer n;
begin
integer fact, i;
fact := 1;
if n > 1 then
for i := 2 step 1 until n do
fact := fact * i;
for i := 2 step 1 until n do
fact := fact * i;
factorial := fact
end;
outint( factorial( 6 ), 5);
outimage
integer f; outtext("factorials:"); outimage;
for f := 0, 1, 2, 6, 9 do begin
outint(f, 2); outint(factorial(f), 8); outimage
end
end