Theorem: List.mk_mem_sym2
File: Mathlib/Data/List/Sym.lean

tactic: simp at ha
state_before: case nil
α : Type u_1
a b : α
ha : a ∈ []
hb : b ∈ []
⊢ s(a, b) ∈ [].sym2
state_after: no goals

tactic: rw [mem_sym2_cons_iff]
state_before: case cons
α : Type u_1
a b x : α
xs : List α
ih : a ∈ xs → b ∈ xs → s(a, b) ∈ xs.sym2
ha : a ∈ x :: xs
hb : b ∈ x :: xs
⊢ s(a, b) ∈ (x :: xs).sym2
state_after: case cons
α : Type u_1
a b x : α
xs : List α
ih : a ∈ xs → b ∈ xs → s(a, b) ∈ xs.sym2
ha : a ∈ x :: xs
hb : b ∈ x :: xs
⊢ s(a, b) = s(x, x) ∨ (∃ y ∈ xs, s(a, b) = s(x, y)) ∨ s(a, b) ∈ xs.sym2

tactic: rw [mem_cons] at ha hb
state_before: case cons
α : Type u_1
a b x : α
xs : List α
ih : a ∈ xs → b ∈ xs → s(a, b) ∈ xs.sym2
ha : a ∈ x :: xs
hb : b ∈ x :: xs
⊢ s(a, b) = s(x, x) ∨ (∃ y ∈ xs, s(a, b) = s(x, y)) ∨ s(a, b) ∈ xs.sym2
state_after: case cons
α : Type u_1
a b x : α
xs : List α
ih : a ∈ xs → b ∈ xs → s(a, b) ∈ xs.sym2
ha : a = x ∨ a ∈ xs
hb : b = x ∨ b ∈ xs
⊢ s(a, b) = s(x, x) ∨ (∃ y ∈ xs, s(a, b) = s(x, y)) ∨ s(a, b) ∈ xs.sym2

tactic: obtain (rfl | ha) := ha <;> obtain (rfl | hb) := hb
state_before: case cons
α : Type u_1
a b x : α
xs : List α
ih : a ∈ xs → b ∈ xs → s(a, b) ∈ xs.sym2
ha : a = x ∨ a ∈ xs
hb : b = x ∨ b ∈ xs
⊢ s(a, b) = s(x, x) ∨ (∃ y ∈ xs, s(a, b) = s(x, y)) ∨ s(a, b) ∈ xs.sym2
state_after: case cons.inl.inl
α : Type u_1
b : α
xs : List α
ih : b ∈ xs → b ∈ xs → s(b, b) ∈ xs.sym2
⊢ s(b, b) = s(b, b) ∨ (∃ y ∈ xs, s(b, b) = s(b, y)) ∨ s(b, b) ∈ xs.sym2

case cons.inl.inr
α : Type u_1
a b : α
xs : List α
ih : a ∈ xs → b ∈ xs → s(a, b) ∈ xs.sym2
hb : b ∈ xs
⊢ s(a, b) = s(a, a) ∨ (∃ y ∈ xs, s(a, b) = s(a, y)) ∨ s(a, b) ∈ xs.sym2

case cons.inr.inl
α : Type u_1
a b : α
xs : List α
ih : a ∈ xs → b ∈ xs → s(a, b) ∈ xs.sym2
ha : a ∈ xs
⊢ s(a, b) = s(b, b) ∨ (∃ y ∈ xs, s(a, b) = s(b, y)) ∨ s(a, b) ∈ xs.sym2

case cons.inr.inr
α : Type u_1
a b x : α
xs : List α
ih : a ∈ xs → b ∈ xs → s(a, b) ∈ xs.sym2
ha : a ∈ xs
hb : b ∈ xs
⊢ s(a, b) = s(x, x) ∨ (∃ y ∈ xs, s(a, b) = s(x, y)) ∨ s(a, b) ∈ xs.sym2

tactic: left
state_before: case cons.inl.inl
α : Type u_1
b : α
xs : List α
ih : b ∈ xs → b ∈ xs → s(b, b) ∈ xs.sym2
⊢ s(b, b) = s(b, b) ∨ (∃ y ∈ xs, s(b, b) = s(b, y)) ∨ s(b, b) ∈ xs.sym2
state_after: case cons.inl.inl.h
α : Type u_1
b : α
xs : List α
ih : b ∈ xs → b ∈ xs → s(b, b) ∈ xs.sym2
⊢ s(b, b) = s(b, b)

tactic: rfl
state_before: case cons.inl.inl.h
α : Type u_1
b : α
xs : List α
ih : b ∈ xs → b ∈ xs → s(b, b) ∈ xs.sym2
⊢ s(b, b) = s(b, b)
state_after: no goals

tactic: right
state_before: case cons.inl.inr
α : Type u_1
a b : α
xs : List α
ih : a ∈ xs → b ∈ xs → s(a, b) ∈ xs.sym2
hb : b ∈ xs
⊢ s(a, b) = s(a, a) ∨ (∃ y ∈ xs, s(a, b) = s(a, y)) ∨ s(a, b) ∈ xs.sym2
state_after: case cons.inl.inr.h
α : Type u_1
a b : α
xs : List α
ih : a ∈ xs → b ∈ xs → s(a, b) ∈ xs.sym2
hb : b ∈ xs
⊢ (∃ y ∈ xs, s(a, b) = s(a, y)) ∨ s(a, b) ∈ xs.sym2

tactic: left
state_before: case cons.inl.inr.h
α : Type u_1
a b : α
xs : List α
ih : a ∈ xs → b ∈ xs → s(a, b) ∈ xs.sym2
hb : b ∈ xs
⊢ (∃ y ∈ xs, s(a, b) = s(a, y)) ∨ s(a, b) ∈ xs.sym2
state_after: case cons.inl.inr.h.h
α : Type u_1
a b : α
xs : List α
ih : a ∈ xs → b ∈ xs → s(a, b) ∈ xs.sym2
hb : b ∈ xs
⊢ ∃ y ∈ xs, s(a, b) = s(a, y)

tactic: use b
state_before: case cons.inl.inr.h.h
α : Type u_1
a b : α
xs : List α
ih : a ∈ xs → b ∈ xs → s(a, b) ∈ xs.sym2
hb : b ∈ xs
⊢ ∃ y ∈ xs, s(a, b) = s(a, y)
state_after: no goals

tactic: right
state_before: case cons.inr.inl
α : Type u_1
a b : α
xs : List α
ih : a ∈ xs → b ∈ xs → s(a, b) ∈ xs.sym2
ha : a ∈ xs
⊢ s(a, b) = s(b, b) ∨ (∃ y ∈ xs, s(a, b) = s(b, y)) ∨ s(a, b) ∈ xs.sym2
state_after: case cons.inr.inl.h
α : Type u_1
a b : α
xs : List α
ih : a ∈ xs → b ∈ xs → s(a, b) ∈ xs.sym2
ha : a ∈ xs
⊢ (∃ y ∈ xs, s(a, b) = s(b, y)) ∨ s(a, b) ∈ xs.sym2

tactic: left
state_before: case cons.inr.inl.h
α : Type u_1
a b : α
xs : List α
ih : a ∈ xs → b ∈ xs → s(a, b) ∈ xs.sym2
ha : a ∈ xs
⊢ (∃ y ∈ xs, s(a, b) = s(b, y)) ∨ s(a, b) ∈ xs.sym2
state_after: case cons.inr.inl.h.h
α : Type u_1
a b : α
xs : List α
ih : a ∈ xs → b ∈ xs → s(a, b) ∈ xs.sym2
ha : a ∈ xs
⊢ ∃ y ∈ xs, s(a, b) = s(b, y)

tactic: rw [Sym2.eq_swap]
state_before: case cons.inr.inl.h.h
α : Type u_1
a b : α
xs : List α
ih : a ∈ xs → b ∈ xs → s(a, b) ∈ xs.sym2
ha : a ∈ xs
⊢ ∃ y ∈ xs, s(a, b) = s(b, y)
state_after: case cons.inr.inl.h.h
α : Type u_1
a b : α
xs : List α
ih : a ∈ xs → b ∈ xs → s(a, b) ∈ xs.sym2
ha : a ∈ xs
⊢ ∃ y ∈ xs, s(b, a) = s(b, y)

tactic: use a
state_before: case cons.inr.inl.h.h
α : Type u_1
a b : α
xs : List α
ih : a ∈ xs → b ∈ xs → s(a, b) ∈ xs.sym2
ha : a ∈ xs
⊢ ∃ y ∈ xs, s(b, a) = s(b, y)
state_after: no goals

tactic: right
state_before: case cons.inr.inr
α : Type u_1
a b x : α
xs : List α
ih : a ∈ xs → b ∈ xs → s(a, b) ∈ xs.sym2
ha : a ∈ xs
hb : b ∈ xs
⊢ s(a, b) = s(x, x) ∨ (∃ y ∈ xs, s(a, b) = s(x, y)) ∨ s(a, b) ∈ xs.sym2
state_after: case cons.inr.inr.h
α : Type u_1
a b x : α
xs : List α
ih : a ∈ xs → b ∈ xs → s(a, b) ∈ xs.sym2
ha : a ∈ xs
hb : b ∈ xs
⊢ (∃ y ∈ xs, s(a, b) = s(x, y)) ∨ s(a, b) ∈ xs.sym2

tactic: right
state_before: case cons.inr.inr.h
α : Type u_1
a b x : α
xs : List α
ih : a ∈ xs → b ∈ xs → s(a, b) ∈ xs.sym2
ha : a ∈ xs
hb : b ∈ xs
⊢ (∃ y ∈ xs, s(a, b) = s(x, y)) ∨ s(a, b) ∈ xs.sym2
state_after: case cons.inr.inr.h.h
α : Type u_1
a b x : α
xs : List α
ih : a ∈ xs → b ∈ xs → s(a, b) ∈ xs.sym2
ha : a ∈ xs
hb : b ∈ xs
⊢ s(a, b) ∈ xs.sym2

tactic: exact ih ha hb
state_before: case cons.inr.inr.h.h
α : Type u_1
a b x : α
xs : List α
ih : a ∈ xs → b ∈ xs → s(a, b) ∈ xs.sym2
ha : a ∈ xs
hb : b ∈ xs
⊢ s(a, b) ∈ xs.sym2
state_after: no goals