| x = firstn(# x - 1 + # z, x) + a ' + z ⊦ firstn(# x - # z, x).last = a |
∀ z, a. x0 = firstn(# x0 - 1 + # z, x0) + a ' + z → firstn(# x0 - # z, x0).last = a, a0 + x0 = firstn(#(a0 + x0) - 1 + # z, a0 + x0) + a ' + z ⊦ firstn(#(a0 + x0) - # z, a0 + x0).last = a
Used simplifier rules: firstN-empty: ⊦ firstn(n, x) = [] ↔ n = 0;%list freely generated by [], +;;%size-01: ⊦ # [] = 0; from specification list-data%a: ⊦ (x + y) + z = x + y + z; from specification list%app-02-ant: ⊦ ¬ x + y ≠ [] ↔ x = [] ∧ y = []; from specification list%e-01: ⊦ a ' + x ≠ []; from specification list