(0) Obligation:
Generalized rewrite system (where rules with free variables on rhs are allowed):
The TRS R consists of the following rules:
and(true) → X
if(true) → X
if(false) → Y
add(0) → X
and(false) → false
add(s) → s
first(0, X) → nil
first(s, cons) → cons
from → cons