no goals
α : Type u_1
as bs : List α
cs ds : Array α
h : toArrayAux as cs = toArrayAux bs ds
hlen : Array.size cs = Array.size ds
⊢ as = bs ∧ cs = ds
match as, bs with
| [], []    => simp [toArrayAux] at h; simp [h]
| a::as, [] => simp [toArrayAux] at h; rw [← h] at hlen; simp_arith [size_toArrayAux] at hlen
| [], b::bs => simp [toArrayAux] at h; rw [h] at hlen; simp_arith [size_toArrayAux] at hlen
| a::as, b::bs =>
  simp [toArrayAux] at h
  have : (cs.push a).size = (ds.push b).size := by simp [*]
  have ⟨ih₁, ih₂⟩ := of_toArrayAux_eq_toArrayAux h this
  simp [ih₁]
  have := Array.of_push_eq_push ih₂
  simp [this]
α : Type u_1
as bs : List α
cs ds : Array α
hlen : Array.size cs = Array.size ds
h : cs = ds
⊢ [] = [] ∧ cs = ds
α : Type u_1
as bs : List α
cs ds : Array α
hlen : Array.size cs = Array.size ds
h : toArrayAux [] cs = toArrayAux [] ds
⊢ [] = [] ∧ cs = ds
simp [toArrayAux] at h
no goals
α : Type u_1
as bs : List α
cs ds : Array α
hlen : Array.size cs = Array.size ds
h : cs = ds
⊢ [] = [] ∧ cs = ds
simp [h]
α : Type u_1
as✝ bs : List α
cs ds : Array α
hlen : Array.size cs = Array.size ds
a : α
as : List α
h : toArrayAux as (Array.push cs a) = ds
⊢ a :: as = [] ∧ cs = ds
α : Type u_1
as✝ bs : List α
cs ds : Array α
hlen : Array.size cs = Array.size ds
a : α
as : List α
h : toArrayAux (a :: as) cs = toArrayAux [] ds
⊢ a :: as = [] ∧ cs = ds
simp [toArrayAux] at h
α : Type u_1
as✝ bs : List α
cs ds : Array α
a : α
as : List α
hlen : Array.size cs = Array.size (toArrayAux as (Array.push cs a))
h : toArrayAux as (Array.push cs a) = ds
⊢ a :: as = [] ∧ cs = ds
α : Type u_1
as✝ bs : List α
cs ds : Array α
hlen : Array.size cs = Array.size ds
a : α
as : List α
h : toArrayAux as (Array.push cs a) = ds
⊢ a :: as = [] ∧ cs = ds
rw [← h] at hlen
no goals
α : Type u_1
as✝ bs : List α
cs ds : Array α
a : α
as : List α
hlen : Array.size cs = Array.size (toArrayAux as (Array.push cs a))
h : toArrayAux as (Array.push cs a) = ds
⊢ a :: as = [] ∧ cs = ds
simp_arith [size_toArrayAux] at hlen
α : Type u_1
as bs✝ : List α
cs ds : Array α
hlen : Array.size cs = Array.size ds
b : α
bs : List α
h : cs = toArrayAux bs (Array.push ds b)
⊢ [] = b :: bs ∧ cs = ds
α : Type u_1
as bs✝ : List α
cs ds : Array α
hlen : Array.size cs = Array.size ds
b : α
bs : List α
h : toArrayAux [] cs = toArrayAux (b :: bs) ds
⊢ [] = b :: bs ∧ cs = ds
simp [toArrayAux] at h
α : Type u_1
as bs✝ : List α
cs ds : Array α
b : α
bs : List α
hlen : Array.size (toArrayAux bs (Array.push ds b)) = Array.size ds
h : cs = toArrayAux bs (Array.push ds b)
⊢ [] = b :: bs ∧ cs = ds
α : Type u_1
as bs✝ : List α
cs ds : Array α
hlen : Array.size cs = Array.size ds
b : α
bs : List α
h : cs = toArrayAux bs (Array.push ds b)
⊢ [] = b :: bs ∧ cs = ds
rw [h] at hlen
no goals
α : Type u_1
as bs✝ : List α
cs ds : Array α
b : α
bs : List α
hlen : Array.size (toArrayAux bs (Array.push ds b)) = Array.size ds
h : cs = toArrayAux bs (Array.push ds b)
⊢ [] = b :: bs ∧ cs = ds
simp_arith [size_toArrayAux] at hlen
α : Type u_1
as✝ bs✝ : List α
cs ds : Array α
hlen : Array.size cs = Array.size ds
a : α
as : List α
b : α
bs : List α
h : toArrayAux as (Array.push cs a) = toArrayAux bs (Array.push ds b)
⊢ a :: as = b :: bs ∧ cs = ds
α : Type u_1
as✝ bs✝ : List α
cs ds : Array α
hlen : Array.size cs = Array.size ds
a : α
as : List α
b : α
bs : List α
h : toArrayAux (a :: as) cs = toArrayAux (b :: bs) ds
⊢ a :: as = b :: bs ∧ cs = ds
simp [toArrayAux] at h
α : Type u_1
as✝ bs✝ : List α
cs ds : Array α
hlen : Array.size cs = Array.size ds
a : α
as : List α
b : α
bs : List α
h : toArrayAux as (Array.push cs a) = toArrayAux bs (Array.push ds b)
this : Array.size (Array.push cs a) = Array.size (Array.push ds b)
⊢ a :: as = b :: bs ∧ cs = ds
α : Type u_1
as✝ bs✝ : List α
cs ds : Array α
hlen : Array.size cs = Array.size ds
a : α
as : List α
b : α
bs : List α
h : toArrayAux as (Array.push cs a) = toArrayAux bs (Array.push ds b)
⊢ a :: as = b :: bs ∧ cs = ds
have : (cs.push a).size = (ds.push b).size := by simp [*]
α : Type u_1
as✝ bs✝ : List α
cs ds : Array α
hlen : Array.size cs = Array.size ds
a : α
as : List α
b : α
bs : List α
h : toArrayAux as (Array.push cs a) = toArrayAux bs (Array.push ds b)
this : Array.size (Array.push cs a) = Array.size (Array.push ds b)
ih₁ : as = bs
ih₂ : Array.push cs a = Array.push ds b
⊢ a :: as = b :: bs ∧ cs = ds
α : Type u_1
as✝ bs✝ : List α
cs ds : Array α
hlen : Array.size cs = Array.size ds
a : α
as : List α
b : α
bs : List α
h : toArrayAux as (Array.push cs a) = toArrayAux bs (Array.push ds b)
this : Array.size (Array.push cs a) = Array.size (Array.push ds b)
⊢ a :: as = b :: bs ∧ cs = ds
have ⟨ih₁, ih₂⟩ := of_toArrayAux_eq_toArrayAux h this
α : Type u_1
as✝ bs✝ : List α
cs ds : Array α
hlen : Array.size cs = Array.size ds
a : α
as : List α
b : α
bs : List α
h : toArrayAux as (Array.push cs a) = toArrayAux bs (Array.push ds b)
this : Array.size (Array.push cs a) = Array.size (Array.push ds b)
ih₁ : as = bs
ih₂ : Array.push cs a = Array.push ds b
⊢ a = b ∧ cs = ds
α : Type u_1
as✝ bs✝ : List α
cs ds : Array α
hlen : Array.size cs = Array.size ds
a : α
as : List α
b : α
bs : List α
h : toArrayAux as (Array.push cs a) = toArrayAux bs (Array.push ds b)
this : Array.size (Array.push cs a) = Array.size (Array.push ds b)
ih₁ : as = bs
ih₂ : Array.push cs a = Array.push ds b
⊢ a :: as = b :: bs ∧ cs = ds
simp [ih₁]
α : Type u_1
as✝ bs✝ : List α
cs ds : Array α
hlen : Array.size cs = Array.size ds
a : α
as : List α
b : α
bs : List α
h : toArrayAux as (Array.push cs a) = toArrayAux bs (Array.push ds b)
this✝ : Array.size (Array.push cs a) = Array.size (Array.push ds b)
ih₁ : as = bs
ih₂ : Array.push cs a = Array.push ds b
this : cs = ds ∧ a = b
⊢ a = b ∧ cs = ds
α : Type u_1
as✝ bs✝ : List α
cs ds : Array α
hlen : Array.size cs = Array.size ds
a : α
as : List α
b : α
bs : List α
h : toArrayAux as (Array.push cs a) = toArrayAux bs (Array.push ds b)
this : Array.size (Array.push cs a) = Array.size (Array.push ds b)
ih₁ : as = bs
ih₂ : Array.push cs a = Array.push ds b
⊢ a = b ∧ cs = ds
have := Array.of_push_eq_push ih₂
no goals
α : Type u_1
as✝ bs✝ : List α
cs ds : Array α
hlen : Array.size cs = Array.size ds
a : α
as : List α
b : α
bs : List α
h : toArrayAux as (Array.push cs a) = toArrayAux bs (Array.push ds b)
this✝ : Array.size (Array.push cs a) = Array.size (Array.push ds b)
ih₁ : as = bs
ih₂ : Array.push cs a = Array.push ds b
this : cs = ds ∧ a = b
⊢ a = b ∧ cs = ds
simp [this]
no goals
α : Type u_1
as✝ bs✝ : List α
cs ds : Array α
hlen : Array.size cs = Array.size ds
a : α
as : List α
b : α
bs : List α
h : toArrayAux as (Array.push cs a) = toArrayAux bs (Array.push ds b)
⊢ Array.size (Array.push cs a) = Array.size (Array.push ds b)
simp [*]