Proof using.
intros c a b l; elim c; simpl in |- *; auto.
intros; discriminate.
intros a0; case a0.
intros a1; case (eqA_dec a a1); simpl in |- *; auto.
intros e l0 l1 H H0; left;
apply f_equal2 with (f := pair (A:=A) (B:=list bool));
auto.
Qed.

(* What is in the code can be found by find_code *)
Theorem find_code_correct2 :
forall (c : code) (a : A) (l : list bool),
unique_key c -> In (a, l) c -> find_code a c = l.