The first thing to note for this example is that there are no axioms which have push as the left-most operation on the left-hand side of an axiom. Therefore, for the first reduction, looking down the list of axioms, we look for any axioms that have pop as the first operation on their left-hand side. The first such axiom, pop(init) = stack-error cannot be used since init is not a variable, but the second axiom pop(push(s,n)) = s can be applied, with the left-hand side L as pop(push(s,n)), and the right-hand side R as s. The appropriate unifier is
The subterm u of t is now replaced by the right-hand side of the rewrite rule R, with all variables in the substitutions replaced by their corresponding terms. Hence the subterm u of t rewrites to the value init and the term t becomes