Proof using.
intros.
invc H.
invc H4.
- rewrite app_nil_r in *. subst. auto.
- invc H1. invc H. discriminate.
Qed.

(* Specifications: *)
Lemma step_1_singleton_inversion :
forall st st' i os,
step_1 st st' [(i, os)] ->
handler i st = (os, st').