Name: test/0
Name: test2/0
app([],L,L). app([H|T],Y,[H|Z]) :- app(T,Y,Z).
Calls:
Name: RECURSIVE_CALL/3
Called:
Name: nrev/2
gen(Nr,[]) :- Nr<1,!. gen(Nr,[Nr|T]) :- N1 is Nr-1, gen(N1,T).
Name: RECURSIVE_CALL/2
Name: is/2
Name: !
Name: </2
gen2(Nr,[]) :- Nr<1,!. gen2(Nr,[f(Nr)|T]) :- N1 is Nr-1, gen2(N1,T).
nrev( [] ,[] ). nrev( [H|L] , R) :- nrev(L,RL), app( RL, [H], R ).
Name: app/3
p(h). p(f(X)) :- X<2,!. p(f(X)) :- p(g(X)). p(g(X)) :- number(X).
Name: number/1
Name: RECURSIVE_CALL/1
Name: p3/1
p2(h). p2(f(X)) :- p3(X). p2(g(X)) :- number(X).
p3(X) :- X<2,!. p3(X) :- p(g(X)).
Name: p/1
Name: p2/1
pl1(L) :- maplist(p,L).
Name: maplist/2
pl2(L) :- maplist(p2,L).
test :- gen(1000,L), nrev(L,RL), print(RL),nl.
Name: nl
Name: print/1
Name: gen/2
test2 :- gen2(100000,L), pl1(L), pl2(L), profiler:pen.
Name: pen/0
Name: pl2/1
Name: pl1/1
Name: gen2/2
Dynamic: true
Block: waiting_add(?,?,-) waiting_add(?,-,?)
waiting_add(S,A,B) :- S is A + B.