(* This code is copyrighted by its authors; it is distributed under  *)
(* the terms of the LGPL license (see LICENSE and description files) *)
intros A B f b xs; elim xs; simpl in |- *; auto.
intros H'; elim H'; auto.
intros a l H' H'0; elim H'0;
[ intros H'1; clear H'0 | intros H'1; clear H'0 ];
auto.
exists a; split; auto.
elim H'; [ intros a0 E; elim E; intros H'2 H'3; clear E H' | clear H' ]; auto.
exists a0; split; auto.
Qed.
intros A B f l1; elim l1; simpl in |- *; auto with datatypes.
intros a l H' l2; rewrite H'; auto.
Qed.
intros A B f l; elim l; simpl in |- *; auto.
intros a l0 H'; rewrite <- H'; simpl in |- *; auto.
apply trans_equal with (y := map f (rev l0) ++ map f (a :: nil)); auto.
apply map_app; auto.
Qed.

Lemma rev_in : forall (A : Set) (a : A) (l : list A), In a (rev l) -> In a l.