simp only [mapM', Option.pure_eq_some, Option.bind_eq_bind, Option.bind_eq_some,
Option.some.injEq] at h
case cons
α✝ : Type u
inst✝² : DecidableEq α✝
β✝ : Type v
inst✝¹ : DecidableEq β✝
m : Type ?u.157952 → Type ?u.157954
α : Type u_2
β : Type u_1
inst✝ : Monad m
b : β
f : α → Option β
a : α
as : List α
ih : ∀ {bs : List β}, mapM' f as = some bs → b ∈ bs → ∃ a, f a = some b
bs : List β
h : mapM' f (a :: as) = some bs
hb : b ∈ bs
⊢ ∃ a, f a = some b
case cons
α✝ : Type u
inst✝² : DecidableEq α✝
β✝ : Type v
inst✝¹ : DecidableEq β✝
m : Type ?u.157952 → Type ?u.157954
α : Type u_2
β : Type u_1
inst✝ : Monad m
b : β
f : α → Option β
a : α
as : List α
ih : ∀ {bs : List β}, mapM' f as = some bs → b ∈ bs → ∃ a, f a = some b
bs : List β
hb : b ∈ bs
h : ∃ a_1, f a = some a_1 ∧ ∃ a, mapM' f as = some a ∧ a_1 :: a = bs
⊢ ∃ a, f a = some b