DataMuseum.dk

Presents historical artifacts from the history of:

Rational R1000/400 Tapes

This is an automatic "excavation" of a thematic subset of
artifacts from Datamuseum.dk's BitArchive.

See our Wiki for more about Rational R1000/400 Tapes

Excavated with: AutoArchaeologist - Free & Open Source Software.


top - metrics - download
Index: B T

⟦75a3d3bab⟧ TextFile

    Length: 755 (0x2f3)
    Types: TextFile
    Names: »B«

Derivation

└─⟦180fe333a⟧ Bits:30000405 8mm tape, Rational 1000, SW CATALOG, 10_20_0
└─⟦180fe333a⟧ Bits:30000537 8mm tape, Rational 1000, SW Catalog 10_20_0
    └─⟦5cb1d1d7f⟧ »DATA« 
        └─⟦3b1ee7bd8⟧ 
            └─⟦this⟧ 

TextFile

-- DETERMINES VALUE! USING A RECURSIVE FUNCTION


with Instrument;
use Instrument;

procedure Facta1 is
    V : Integer;
    Fact : constant Integer := 12;
    Cycle : constant Integer := 1000;
    function Factorial (Value : in Integer) return Integer is

    begin

        if

           Value = 1

            then

            return 1;

        else

            return (Value * Factorial (Value - 1));

        end if;

    end Factorial;


begin

    Start ("FACTA1", " RECURSIVE FUNCTION FOR VALUE! CALLED 1000 TIMES");
    for I in 1 .. Cycle loop
        --     V := FACTORIAL(FACT);
        V := Ident_Int (V);
    end loop;
    -- COMMENT("FACTORIAL OF "&INTEGER'IMAGE(FACT)&" IS " &
    --          INTEGER'IMAGE(V));
    Stop;
end Facta1;