proposition: Lemma kth_S_plus : forall k n, kth_S k n = n + k + 1.
proof: Proof. induction k. intro. unfold kth_S. rewrite Nat.add_0_r. rewrite plus_1_r. reflexivity. intro. unfold kth_S. fold kth_S. rewrite IHk. assert (n + S k + 1=S k + n +1). auto with arith. rewrite H. clear H. simpl. auto with arith. Qed.
imports: PeanoNat Compare