induction ls; intuition; simpl in *.
case_eq (eqb d a0); intuition;
rewrite H0 in H.
discriminate.
case_eq (eqb d' d); intuition.
rewrite eqb_leibniz in H1.
subst.
case_eq (eqb d a0); intuition.
rewrite eqb_leibniz in H1.
subst.
rewrite eqb_refl in H0.
discriminate.
eapply arrayLookup_app_some_eq.
trivial.
specialize (IHls d d').
case_eq (eqb d' a0); intuition.
rewrite H1 in IHls.
eapply IHls.
trivial.
Qed.

(* Specifications: *)
Lemma arrayLookup_app_ne : forall ls d r d',
d <> d' ->
arrayLookup (ls ++ (d, r) :: nil) d' = arrayLookup ls d'.