我想将不完整的列表转换为差异列表,反之亦然.
这是将常规列表转换为差异的代码:
reg2diff(L,X-Y):-append(L,Y,X).
我该怎么走另一个方向?
prolog difference-lists
difference-lists ×1
prolog ×1