![]() |
how to replace element in difference list of prolog??
hi: want to replace all elements with the number of its depth in the difference list in prolog. such as: ?- deepList([a, [b]], L). L = [0, [1]]. ?- deepList([a, [b, c, [d, e]], f], L). L = [0, [1, 1, [2, 2]], 0]. Thank!
|
| All times are GMT -4. The time now is 07:29 PM. |
Powered by vBulletin®
Copyright ©2000 - 2026, Jelsoft Enterprises Ltd.