Reversing the item order of a list in prolog

后端 未结 0 975
花落未央
花落未央 2020-11-22 02:01

Can somebody explain to me the following code:

t(L, NL) :-
    t(L, [], NL).
t([], L, L). 
t([H|T], A, NL) :-
    t(T, [H|A], NL).

I would ha

相关标签:
回答
  • 消灭零回复
提交回复
热议问题