(* If two environments that agree up to [k] are extended with a new variable, then they agree up to [k+1]. *)

Lemma agree_insert:
forall A (e1 e2 : env A) k,
agree e1 e2 k ->
forall x o,
x <= k ->
agree (raw_insert x o e1) (raw_insert x o e2) (1 + k).