/home/nowonder/forschung/aprove/TPDB05/TRS/TRCSR/Ex6_Luc98_GM.trs

The program

(VAR X Y Z X1 X2)
(RULES 
a__first(0,X) -> nil
a__first(s(X),cons(Y,Z)) -> cons(mark(Y),first(X,Z))
a__from(X) -> cons(mark(X),from(s(X)))
mark(first(X1,X2)) -> a__first(mark(X1),mark(X2))
mark(from(X)) -> a__from(mark(X))
mark(0) -> 0
mark(nil) -> nil
mark(s(X)) -> s(mark(X))
mark(cons(X1,X2)) -> cons(mark(X1),X2)
a__first(X1,X2) -> first(X1,X2)
a__from(X) -> from(X)
)

Submit to AProVE Web Frontend

Edit in AProVE Web Frontend