proposition: Lemma lookup_difference_with_Some {A} (f : A → A → option A) (m1 m2 : M A) i z : difference_with f m1 m2 !! i = Some z ↔ (m1 !! i = Some z ∧ m2 !! i = None) ∨ (∃ x y, m1 !! i = Some x ∧ m2 !! i = Some y ∧ f x y = Some z).
proof: Proof. rewrite lookup_difference_with. destruct (m1 !! i), (m2 !! i); compute; naive_solver. Qed.
imports: Coq(Permutation) stdpp(options)