Example



next up previous WS Presentations Main Page
Next: Active Modules / Up: Document: ciao Previous: Example

Example

% :- module(fib,[fib/2],ciao(h)).
:- module(fib,[fib/2],andorra(h)).
:- entry(fib(g,f)).
fib(0,1).
fib(1,1).
fib(A,B) :-
        A>1,
        C is A-1,
        D is A-2,
        fib(C,E),
        fib(D,F),
        B is F+E.



Thu Jan 18 11:29:48 MET 1996 <herme@fi.upm.es>-<webmaster@clip.dia.fi.upm.es>