Documentation

Acmoi.Exercise7_2

def width {n : } :
List (Fin n)
Equations
theorem width_nil {n : } :
width [] = 0
theorem width_single {n : } (a : Fin n.succ) :
width [a] = 1
theorem width_stay {n : } (a : Fin n.succ) (x : List (Fin n.succ)) (h : a x.toFinset) :
width (a :: x) = width x
def disjoint_lists {α : Type} [DecidableEq α] (x : List α) (y : List α) :
Equations
theorem width_disjoint {n : } {x : List (Fin n)} {y : List (Fin n)} (h : disjoint_lists x y) :
width (x ++ y) = width x + width y
theorem width_comm {n : } (x : List (Fin n)) (y : List (Fin n)) :
width (x ++ y) = width (y ++ x)
theorem width_append {n : } (x : List (Fin n)) (y : List (Fin n)) :
width (x ++ y) width x + width y