File: .lake/packages/lean4/src/lean/Init/Data/Bool.lean

full_name: xor
code: /-- Boolean exclusive or -/
abbrev xor : Bool → Bool → Bool 
goal: Bool → Bool → Bool

full_name: Bool.not
code: @[inherit_doc not] protected abbrev not 
goal: Bool → Bool

full_name: Bool.or
code: @[inherit_doc or]  protected abbrev or  
goal: Bool

full_name: Bool.and
code: @[inherit_doc and] protected abbrev and 
goal: Bool

full_name: Bool.xor
code: @[inherit_doc xor] protected abbrev xor 
goal: Bool → Bool → Bool

full_name: Bool.«instDecidableForallOfDecidablePred_.lake»
code: instance (p : Bool → Prop) [inst : DecidablePred p] : Decidable (∀ x, p x) 
goal: Decidable (∀ (x : Bool), p x)

full_name: Bool.«instDecidableExistsOfDecidablePred_.lake»
code: instance (p : Bool → Prop) [inst : DecidablePred p] : Decidable (∃ x, p x) 
goal: Decidable (∃ x, p x)

full_name: Bool.default_bool
code: @[simp] theorem default_bool : default = false 
goal: default = false

full_name: Bool.«instLE_.lake»
code: instance : LE Bool 
goal: LE Bool

full_name: Bool.«instLT_.lake»
code: instance : LT Bool 
goal: LT Bool

full_name: Bool.«instDecidableLe_.lake»
code: instance (x y : Bool) : Decidable (x ≤ y) 
goal: Decidable (x ≤ y)

full_name: Bool.«instDecidableLt_.lake»
code: instance (x y : Bool) : Decidable (x < y) 
goal: Decidable (x < y)

full_name: Bool.«instMax_.lake»
code: instance : Max Bool 
goal: Max Bool

full_name: Bool.«instMin_.lake»
code: instance : Min Bool 
goal: Min Bool

full_name: Bool.false_ne_true
code: theorem false_ne_true : false ≠ true 
goal: false ≠ true

full_name: Bool.eq_false_or_eq_true
code: theorem eq_false_or_eq_true : (b : Bool) → b = true ∨ b = false 
goal: b = true ∨ b = false

full_name: Bool.eq_false_iff
code: theorem eq_false_iff : {b : Bool} → b = false ↔ b ≠ true 
goal: b = false ↔ b ≠ true

full_name: Bool.ne_false_iff
code: theorem ne_false_iff : {b : Bool} → b ≠ false ↔ b = true 
goal: b ≠ false ↔ b = true

full_name: Bool.eq_iff_iff
code: theorem eq_iff_iff {a b : Bool} : a = b ↔ (a ↔ b) 
goal: a = b ↔ (a = true ↔ b = true)

full_name: Bool.decide_eq_true
code: @[simp] theorem decide_eq_true  {b : Bool} [Decidable (b = true)]  : decide (b = true)  =  b 
goal: decide (b = true) = b

full_name: Bool.decide_eq_false
code: @[simp] theorem decide_eq_false {b : Bool} [Decidable (b = false)] : decide (b = false) = !b 
goal: decide (b = false) = !b

full_name: Bool.decide_true_eq
code: @[simp] theorem decide_true_eq  {b : Bool} [Decidable (true = b)]  : decide (true  = b) =  b 
goal: decide (true = b) = b

full_name: Bool.decide_false_eq
code: @[simp] theorem decide_false_eq {b : Bool} [Decidable (false = b)] : decide (false = b) = !b 
goal: decide (false = b) = !b

full_name: Bool.and_self_left
code: @[simp] theorem and_self_left  : ∀(a b : Bool), (a && (a && b)) = (a && b) 
goal: (a && (a && b)) = (a && b)

full_name: Bool.and_self_right
code: @[simp] theorem and_self_right : ∀(a b : Bool), ((a && b) && b) = (a && b) 
goal: (a && b && b) = (a && b)

full_name: Bool.not_and_self
code: @[simp] theorem not_and_self : ∀ (x : Bool), (!x && x) = false 
goal: (!x && x) = false

full_name: Bool.and_not_self
code: @[simp] theorem and_not_self : ∀ (x : Bool), (x && !x) = false 
goal: (x && !x) = false

full_name: Bool.eq_true_and_eq_false_self
code: @[simp] theorem eq_true_and_eq_false_self : ∀(b : Bool), (b = true ∧ b = false) ↔ False 
goal: b = true ∧ b = false ↔ False

full_name: Bool.eq_false_and_eq_true_self
code: @[simp] theorem eq_false_and_eq_true_self : ∀(b : Bool), (b = false ∧ b = true) ↔ False 
goal: b = false ∧ b = true ↔ False

full_name: Bool.and_comm
code: theorem and_comm : ∀ (x y : Bool), (x && y) = (y && x) 
goal: (x && y) = (y && x)

full_name: Bool.«instCommutativeAnd_.lake»
code: instance : Std.Commutative (· && ·) 
goal: Std.Commutative fun x x_1 => x && x_1

full_name: Bool.and_left_comm
code: theorem and_left_comm : ∀ (x y z : Bool), (x && (y && z)) = (y && (x && z)) 
goal: (x && (y && z)) = (y && (x && z))

full_name: Bool.and_right_comm
code: theorem and_right_comm : ∀ (x y z : Bool), ((x && y) && z) = ((x && z) && y) 
goal: (x && y && z) = (x && z && y)

full_name: Bool.and_iff_left_iff_imp
code: @[simp] theorem and_iff_left_iff_imp  : ∀(a b : Bool), ((a && b) = a) ↔ (a → b) 
goal: (a && b) = a ↔ a = true → b = true

full_name: Bool.and_iff_right_iff_imp
code: @[simp] theorem and_iff_right_iff_imp : ∀(a b : Bool), ((a && b) = b) ↔ (b → a) 
goal: (a && b) = b ↔ b = true → a = true

full_name: Bool.iff_self_and
code: @[simp] theorem iff_self_and : ∀(a b : Bool), (a = (a && b)) ↔ (a → b) 
goal: a = (a && b) ↔ a = true → b = true

full_name: Bool.iff_and_self
code: @[simp] theorem iff_and_self : ∀(a b : Bool), (b = (a && b)) ↔ (b → a) 
goal: b = (a && b) ↔ b = true → a = true

full_name: Bool.or_self_left
code: @[simp] theorem or_self_left  : ∀(a b : Bool), (a || (a || b)) = (a || b) 
goal: (a || (a || b)) = (a || b)

full_name: Bool.or_self_right
code: @[simp] theorem or_self_right : ∀(a b : Bool), ((a || b) || b) = (a || b) 
goal: (a || b || b) = (a || b)

full_name: Bool.not_or_self
code: @[simp] theorem not_or_self : ∀ (x : Bool), (!x || x) = true 
goal: (!x || x) = true

full_name: Bool.or_not_self
code: @[simp] theorem or_not_self : ∀ (x : Bool), (x || !x) = true 
goal: (x || !x) = true

full_name: Bool.eq_true_or_eq_false_self
code: @[simp] theorem eq_true_or_eq_false_self : ∀(b : Bool), (b = true ∨ b = false) ↔ True 
goal: b = true ∨ b = false ↔ True

full_name: Bool.eq_false_or_eq_true_self
code: @[simp] theorem eq_false_or_eq_true_self : ∀(b : Bool), (b = false ∨ b = true) ↔ True 
goal: b = false ∨ b = true ↔ True

full_name: Bool.or_iff_left_iff_imp
code: @[simp] theorem or_iff_left_iff_imp  : ∀(a b : Bool), ((a || b) = a) ↔ (b → a) 
goal: (a || b) = a ↔ b = true → a = true

full_name: Bool.or_iff_right_iff_imp
code: @[simp] theorem or_iff_right_iff_imp : ∀(a b : Bool), ((a || b) = b) ↔ (a → b) 
goal: (a || b) = b ↔ a = true → b = true

full_name: Bool.iff_self_or
code: @[simp] theorem iff_self_or : ∀(a b : Bool), (a = (a || b)) ↔ (b → a) 
goal: a = (a || b) ↔ b = true → a = true

full_name: Bool.iff_or_self
code: @[simp] theorem iff_or_self : ∀(a b : Bool), (b = (a || b)) ↔ (a → b) 
goal: b = (a || b) ↔ a = true → b = true

full_name: Bool.or_comm
code: theorem or_comm : ∀ (x y : Bool), (x || y) = (y || x) 
goal: (x || y) = (y || x)

full_name: Bool.«instCommutativeOr_.lake»
code: instance : Std.Commutative (· || ·) 
goal: Std.Commutative fun x x_1 => x || x_1

full_name: Bool.or_left_comm
code: theorem or_left_comm : ∀ (x y z : Bool), (x || (y || z)) = (y || (x || z)) 
goal: (x || (y || z)) = (y || (x || z))

full_name: Bool.or_right_comm
code: theorem or_right_comm : ∀ (x y z : Bool), ((x || y) || z) = ((x || z) || y) 
goal: (x || y || z) = (x || z || y)

full_name: Bool.and_or_distrib_left
code: theorem and_or_distrib_left  : ∀ (x y z : Bool), (x && (y || z)) = (x && y || x && z) 
goal: (x && (y || z)) = (x && y || x && z)

full_name: Bool.and_or_distrib_right
code: theorem and_or_distrib_right : ∀ (x y z : Bool), ((x || y) && z) = (x && z || y && z) 
goal: ((x || y) && z) = (x && z || y && z)

full_name: Bool.or_and_distrib_left
code: theorem or_and_distrib_left  : ∀ (x y z : Bool), (x || y && z) = ((x || y) && (x || z)) 
goal: (x || y && z) = ((x || y) && (x || z))

full_name: Bool.or_and_distrib_right
code: theorem or_and_distrib_right : ∀ (x y z : Bool), (x && y || z) = ((x || z) && (y || z)) 
goal: (x && y || z) = ((x || z) && (y || z))

full_name: Bool.and_xor_distrib_left
code: theorem and_xor_distrib_left : ∀ (x y z : Bool), (x && xor y z) = xor (x && y) (x && z) 
goal: (x && xor y z) = xor (x && y) (x && z)

full_name: Bool.and_xor_distrib_right
code: theorem and_xor_distrib_right : ∀ (x y z : Bool), (xor x y && z) = xor (x && z) (y && z) 
goal: (xor x y && z) = xor (x && z) (y && z)

full_name: Bool.not_and
code: /-- De Morgan's law for boolean and -/
@[simp] theorem not_and : ∀ (x y : Bool), (!(x && y)) = (!x || !y) 
goal: (!(x && y)) = (!x || !y)

full_name: Bool.not_or
code: /-- De Morgan's law for boolean or -/
@[simp] theorem not_or : ∀ (x y : Bool), (!(x || y)) = (!x && !y) 
goal: (!(x || y)) = (!x && !y)

full_name: Bool.and_eq_true_iff
code: theorem and_eq_true_iff (x y : Bool) : (x && y) = true ↔ x = true ∧ y = true 
goal: (x && y) = true ↔ x = true ∧ y = true

full_name: Bool.and_eq_false_iff
code: theorem and_eq_false_iff : ∀ (x y : Bool), (x && y) = false ↔ x = false ∨ y = false 
goal: (x && y) = false ↔ x = false ∨ y = false

full_name: Bool.and_eq_false_imp
code: @[simp] theorem and_eq_false_imp : ∀ (x y : Bool), (x && y) = false ↔ (x = true → y = false) 
goal: (x && y) = false ↔ x = true → y = false

full_name: Bool.or_eq_true_iff
code: @[simp] theorem or_eq_true_iff : ∀ (x y : Bool), (x || y) = true ↔ x = true ∨ y = true 
goal: (x || y) = true ↔ x = true ∨ y = true

full_name: Bool.or_eq_false_iff
code: @[simp] theorem or_eq_false_iff : ∀ (x y : Bool), (x || y) = false ↔ x = false ∧ y = false 
goal: (x || y) = false ↔ x = false ∧ y = false

full_name: Bool.false_eq_true
code: /--
These two rules follow trivially by simp, but are needed to avoid non-termination
in false_eq and true_eq.
-/
@[simp] theorem false_eq_true : (false = true) = False 
goal: (false = true) = False

full_name: Bool.true_eq_false
code: @[simp] theorem true_eq_false : (true = false) = False 
goal: (true = false) = False

full_name: Bool.false_eq
code: @[simp low] theorem false_eq (b : Bool) : (false = b) = (b = false) 
goal: (false = b) = (b = false)

full_name: Bool.true_eq
code: @[simp low] theorem true_eq (b : Bool) : (true = b) = (b = true) 
goal: (true = b) = (b = true)

full_name: Bool.true_beq
code: @[simp] theorem true_beq  : ∀b, (true  == b) =  b 
goal: (true == b) = b

full_name: Bool.false_beq
code: @[simp] theorem false_beq : ∀b, (false == b) = !b 
goal: (false == b) = !b

full_name: Bool.beq_true
code: @[simp] theorem beq_true  : ∀b, (b == true)  =  b 
goal: (b == true) = b

full_name: Bool.«instLawfulIdentityBeqTrue_.lake»
code: instance : Std.LawfulIdentity (· == ·) true 
goal: Std.LawfulIdentity (fun x x_1 => x == x_1) true

full_name: Bool.beq_false
code: @[simp] theorem beq_false : ∀b, (b == false) = !b 
goal: (b == false) = !b

full_name: Bool.true_bne
code: @[simp] theorem true_bne  : ∀(b : Bool), (true  != b) = !b 
goal: (true != b) = !b

full_name: Bool.false_bne
code: @[simp] theorem false_bne : ∀(b : Bool), (false != b) =  b 
goal: (false != b) = b

full_name: Bool.bne_true
code: @[simp] theorem bne_true  : ∀(b : Bool), (b != true)  = !b 
goal: (b != true) = !b

full_name: Bool.bne_false
code: @[simp] theorem bne_false : ∀(b : Bool), (b != false) =  b 
goal: (b != false) = b

full_name: Bool.«instLawfulIdentityBneFalse_.lake»
code: instance : Std.LawfulIdentity (· != ·) false 
goal: Std.LawfulIdentity (fun x x_1 => x != x_1) false

full_name: Bool.not_beq_self
code: @[simp] theorem not_beq_self : ∀ (x : Bool), ((!x) == x) = false 
goal: ((!x) == x) = false

full_name: Bool.beq_not_self
code: @[simp] theorem beq_not_self : ∀ (x : Bool), (x   == !x) = false 
goal: (x == !x) = false

full_name: Bool.not_bne_self
code: @[simp] theorem not_bne_self : ∀ (x : Bool), ((!x) != x) = true 
goal: ((!x) != x) = true

full_name: Bool.bne_not_self
code: @[simp] theorem bne_not_self : ∀ (x : Bool), (x   != !x) = true 
goal: (x != !x) = true

full_name: Bool.not_eq_self
code: @[simp] theorem not_eq_self : ∀(b : Bool), ((!b) = b) ↔ False 
goal: (!b) = b ↔ False

full_name: Bool.eq_not_self
code: @[simp] theorem eq_not_self : ∀(b : Bool), (b = (!b)) ↔ False 
goal: b = !b ↔ False

full_name: Bool.beq_self_left
code: @[simp] theorem beq_self_left  : ∀(a b : Bool), (a == (a == b)) = b 
goal: (a == (a == b)) = b

full_name: Bool.beq_self_right
code: @[simp] theorem beq_self_right : ∀(a b : Bool), ((a == b) == b) = a 
goal: ((a == b) == b) = a

full_name: Bool.bne_self_left
code: @[simp] theorem bne_self_left  : ∀(a b : Bool), (a != (a != b)) = b 
goal: (a != (a != b)) = b

full_name: Bool.bne_self_right
code: @[simp] theorem bne_self_right : ∀(a b : Bool), ((a != b) != b) = a 
goal: ((a != b) != b) = a

full_name: Bool.not_bne_not
code: @[simp] theorem not_bne_not : ∀ (x y : Bool), ((!x) != (!y)) = (x != y) 
goal: ((!x) != !y) = (x != y)

full_name: Bool.bne_assoc
code: @[simp] theorem bne_assoc : ∀ (x y z : Bool), ((x != y) != z) = (x != (y != z)) 
goal: ((x != y) != z) = (x != (y != z))

full_name: Bool.«instAssociativeBne_.lake»
code: instance : Std.Associative (· != ·) 
goal: Std.Associative fun x x_1 => x != x_1

full_name: Bool.bne_left_inj
code: @[simp] theorem bne_left_inj  : ∀ (x y z : Bool), (x != y) = (x != z) ↔ y = z 
goal: (x != y) = (x != z) ↔ y = z

full_name: Bool.bne_right_inj
code: @[simp] theorem bne_right_inj : ∀ (x y z : Bool), (x != z) = (y != z) ↔ x = y 
goal: (x != z) = (y != z) ↔ x = y

full_name: Bool.eq_not_of_ne
code: theorem eq_not_of_ne : ∀ {x y : Bool}, x ≠ y → x = !y 
goal: x ≠ y → x = !y

full_name: Bool.beq_eq_decide_eq
code: theorem beq_eq_decide_eq [BEq α] [LawfulBEq α] [DecidableEq α] (a b : α) :
    (a == b) = decide (a = b) 
goal: (a == b) = decide (a = b)

full_name: Bool.not_eq_not
code: @[simp] theorem not_eq_not : ∀ {a b : Bool}, ¬a = !b ↔ a = b 
goal: ¬a = !b ↔ a = b

full_name: Bool.not_not_eq
code: @[simp] theorem not_not_eq : ∀ {a b : Bool}, ¬(!a) = b ↔ a = b 
goal: ¬(!a) = b ↔ a = b

full_name: Bool.coe_iff_coe
code: @[simp] theorem coe_iff_coe : ∀(a b : Bool), (a ↔ b) ↔ a = b 
goal: (a = true ↔ b = true) ↔ a = b

full_name: Bool.coe_true_iff_false
code: @[simp] theorem coe_true_iff_false  : ∀(a b : Bool), (a ↔ b = false) ↔ a = (!b) 
goal: (a = true ↔ b = false) ↔ a = !b

full_name: Bool.coe_false_iff_true
code: @[simp] theorem coe_false_iff_true  : ∀(a b : Bool), (a = false ↔ b) ↔ (!a) = b 
goal: (a = false ↔ b = true) ↔ (!a) = b

full_name: Bool.coe_false_iff_false
code: @[simp] theorem coe_false_iff_false : ∀(a b : Bool), (a = false ↔ b = false) ↔ (!a) = (!b) 
goal: (a = false ↔ b = false) ↔ (!a) = !b

full_name: Bool.beq_comm
code: theorem beq_comm {α} [BEq α] [LawfulBEq α] {a b : α} : (a == b) = (b == a) 
goal: (a == b) = (b == a)

full_name: Bool.false_xor
code: theorem false_xor : ∀ (x : Bool), xor false x = x 
goal: xor false x = x

full_name: Bool.xor_false
code: theorem xor_false : ∀ (x : Bool), xor x false = x 
goal: xor x false = x

full_name: Bool.true_xor
code: theorem true_xor : ∀ (x : Bool), xor true x = !x 
goal: xor true x = !x

full_name: Bool.xor_true
code: theorem xor_true : ∀ (x : Bool), xor x true = !x 
goal: xor x true = !x

full_name: Bool.not_xor_self
code: theorem not_xor_self : ∀ (x : Bool), xor (!x) x = true 
goal: xor (!x) x = true

full_name: Bool.xor_not_self
code: theorem xor_not_self : ∀ (x : Bool), xor x (!x) = true 
goal: (xor x !x) = true

full_name: Bool.not_xor
code: theorem not_xor : ∀ (x y : Bool), xor (!x) y = !(xor x y) 
goal: xor (!x) y = !xor x y

full_name: Bool.xor_not
code: theorem xor_not : ∀ (x y : Bool), xor x (!y) = !(xor x y) 
goal: (xor x !y) = !xor x y

full_name: Bool.not_xor_not
code: theorem not_xor_not : ∀ (x y : Bool), xor (!x) (!y) = (xor x y) 
goal: (xor (!x) !y) = xor x y

full_name: Bool.xor_self
code: theorem xor_self : ∀ (x : Bool), xor x x = false 
goal: xor x x = false

full_name: Bool.xor_comm
code: theorem xor_comm : ∀ (x y : Bool), xor x y = xor y x 
goal: xor x y = xor y x

full_name: Bool.xor_left_comm
code: theorem xor_left_comm : ∀ (x y z : Bool), xor x (xor y z) = xor y (xor x z) 
goal: xor x (xor y z) = xor y (xor x z)

full_name: Bool.xor_right_comm
code: theorem xor_right_comm : ∀ (x y z : Bool), xor (xor x y) z = xor (xor x z) y 
goal: xor (xor x y) z = xor (xor x z) y

full_name: Bool.xor_assoc
code: theorem xor_assoc : ∀ (x y z : Bool), xor (xor x y) z = xor x (xor y z) 
goal: xor (xor x y) z = xor x (xor y z)

full_name: Bool.xor_left_inj
code: theorem xor_left_inj : ∀ (x y z : Bool), xor x y = xor x z ↔ y = z 
goal: xor x y = xor x z ↔ y = z

full_name: Bool.xor_right_inj
code: theorem xor_right_inj : ∀ (x y z : Bool), xor x z = xor y z ↔ x = y 
goal: xor x z = xor y z ↔ x = y

full_name: Bool.le_true
code: @[simp] protected theorem le_true : ∀ (x : Bool), x ≤ true 
goal: x ≤ true

full_name: Bool.false_le
code: @[simp] protected theorem false_le : ∀ (x : Bool), false ≤ x 
goal: false ≤ x

full_name: Bool.le_refl
code: @[simp] protected theorem le_refl : ∀ (x : Bool), x ≤ x 
goal: x ≤ x

full_name: Bool.lt_irrefl
code: @[simp] protected theorem lt_irrefl : ∀ (x : Bool), ¬ x < x 
goal: ¬x < x

full_name: Bool.le_trans
code: protected theorem le_trans : ∀ {x y z : Bool}, x ≤ y → y ≤ z → x ≤ z 
goal: x ≤ y → y ≤ z → x ≤ z

full_name: Bool.le_antisymm
code: protected theorem le_antisymm : ∀ {x y : Bool}, x ≤ y → y ≤ x → x = y 
goal: x ≤ y → y ≤ x → x = y

full_name: Bool.le_total
code: protected theorem le_total : ∀ (x y : Bool), x ≤ y ∨ y ≤ x 
goal: x ≤ y ∨ y ≤ x

full_name: Bool.lt_asymm
code: protected theorem lt_asymm : ∀ {x y : Bool}, x < y → ¬ y < x 
goal: x < y → ¬y < x

full_name: Bool.lt_trans
code: protected theorem lt_trans : ∀ {x y z : Bool}, x < y → y < z → x < z 
goal: x < y → y < z → x < z

full_name: Bool.lt_iff_le_not_le
code: protected theorem lt_iff_le_not_le : ∀ {x y : Bool}, x < y ↔ x ≤ y ∧ ¬ y ≤ x 
goal: x < y ↔ x ≤ y ∧ ¬y ≤ x

full_name: Bool.lt_of_le_of_lt
code: protected theorem lt_of_le_of_lt : ∀ {x y z : Bool}, x ≤ y → y < z → x < z 
goal: x ≤ y → y < z → x < z

full_name: Bool.lt_of_lt_of_le
code: protected theorem lt_of_lt_of_le : ∀ {x y z : Bool}, x < y → y ≤ z → x < z 
goal: x < y → y ≤ z → x < z

full_name: Bool.le_of_lt
code: protected theorem le_of_lt : ∀ {x y : Bool}, x < y → x ≤ y 
goal: x < y → x ≤ y

full_name: Bool.le_of_eq
code: protected theorem le_of_eq : ∀ {x y : Bool}, x = y → x ≤ y 
goal: x = y → x ≤ y

full_name: Bool.ne_of_lt
code: protected theorem ne_of_lt : ∀ {x y : Bool}, x < y → x ≠ y 
goal: x < y → x ≠ y

full_name: Bool.lt_of_le_of_ne
code: protected theorem lt_of_le_of_ne : ∀ {x y : Bool}, x ≤ y → x ≠ y → x < y 
goal: x ≤ y → x ≠ y → x < y

full_name: Bool.le_of_lt_or_eq
code: protected theorem le_of_lt_or_eq : ∀ {x y : Bool}, x < y ∨ x = y → x ≤ y 
goal: x < y ∨ x = y → x ≤ y

full_name: Bool.eq_true_of_true_le
code: protected theorem eq_true_of_true_le : ∀ {x : Bool}, true ≤ x → x = true 
goal: true ≤ x → x = true

full_name: Bool.eq_false_of_le_false
code: protected theorem eq_false_of_le_false : ∀ {x : Bool}, x ≤ false → x = false 
goal: x ≤ false → x = false

full_name: Bool.max_eq_or
code: @[simp] protected theorem max_eq_or : max = or 
goal: max = or

full_name: Bool.min_eq_and
code: @[simp] protected theorem min_eq_and : min = and 
goal: min = and

full_name: Bool.not_inj
code: theorem not_inj : ∀ {x y : Bool}, (!x) = (!y) → x = y 
goal: (!x) = !y → x = y

full_name: Bool.not_inj_iff
code: theorem not_inj_iff : ∀ {x y : Bool}, (!x) = (!y) ↔ x = y 
goal: (!x) = !y ↔ x = y

full_name: Bool.and_or_inj_right
code: theorem and_or_inj_right : ∀ {m x y : Bool}, (x && m) = (y && m) → (x || m) = (y || m) → x = y 
goal: (x && m) = (y && m) → (x || m) = (y || m) → x = y

full_name: Bool.and_or_inj_right_iff
code: theorem and_or_inj_right_iff :
    ∀ {m x y : Bool}, (x && m) = (y && m) ∧ (x || m) = (y || m) ↔ x = y 
goal: (x && m) = (y && m) ∧ (x || m) = (y || m) ↔ x = y

full_name: Bool.and_or_inj_left
code: theorem and_or_inj_left : ∀ {m x y : Bool}, (m && x) = (m && y) → (m || x) = (m || y) → x = y 
goal: (m && x) = (m && y) → (m || x) = (m || y) → x = y

full_name: Bool.and_or_inj_left_iff
code: theorem and_or_inj_left_iff :
    ∀ {m x y : Bool}, (m && x) = (m && y) ∧ (m || x) = (m || y) ↔ x = y 
goal: (m && x) = (m && y) ∧ (m || x) = (m || y) ↔ x = y

full_name: Bool.toNat
code: /-- convert a `Bool` to a `Nat`, `false -> 0`, `true -> 1` -/
def toNat (b:Bool) : Nat 
goal: Nat

full_name: Bool.toNat_false
code: @[simp] theorem toNat_false : false.toNat = 0 
goal: false.toNat = 0

full_name: Bool.toNat_true
code: @[simp] theorem toNat_true : true.toNat = 1 
goal: true.toNat = 1

full_name: Bool.toNat_le
code: theorem toNat_le (c : Bool) : c.toNat ≤ 1 
goal: c.toNat ≤ 1

full_name: Bool.toNat_le_one
code: @[deprecated toNat_le (since := "2024-02-23")]
abbrev toNat_le_one 
goal: c.toNat ≤ 1

full_name: Bool.toNat_lt
code: theorem toNat_lt (b : Bool) : b.toNat < 2 
goal: b.toNat < 2

full_name: Bool.toNat_eq_zero
code: @[simp] theorem toNat_eq_zero (b : Bool) : b.toNat = 0 ↔ b = false 
goal: b.toNat = 0 ↔ b = false

full_name: Bool.toNat_eq_one
code: @[simp] theorem toNat_eq_one  (b : Bool) : b.toNat = 1 ↔ b = true 
goal: b.toNat = 1 ↔ b = true

full_name: Bool.if_true_left
code: @[simp] theorem if_true_left  (p : Prop) [h : Decidable p] (f : Bool) :
    (ite p true f) = (p || f) 
goal: (if p then true else f) = (decide p || f)

full_name: Bool.if_false_left
code: @[simp] theorem if_false_left  (p : Prop) [h : Decidable p] (f : Bool) :
    (ite p false f) = (!p && f) 
goal: (if p then false else f) = (!decide p && f)

full_name: Bool.if_true_right
code: @[simp] theorem if_true_right  (p : Prop) [h : Decidable p] (t : Bool) :
    (ite p t true) = (!(p : Bool) || t) 
goal: (if p then t else true) = (!decide p || t)

full_name: Bool.if_false_right
code: @[simp] theorem if_false_right  (p : Prop) [h : Decidable p] (t : Bool) :
    (ite p t false) = (p && t) 
goal: (if p then t else false) = (decide p && t)

full_name: Bool.ite_eq_true_distrib
code: @[simp] theorem ite_eq_true_distrib (p : Prop) [h : Decidable p] (t f : Bool) :
    (ite p t f = true) = ite p (t = true) (f = true) 
goal: ((if p then t else f) = true) = if p then t = true else f = true

full_name: Bool.ite_eq_false_distrib
code: @[simp] theorem ite_eq_false_distrib (p : Prop) [h : Decidable p] (t f : Bool) :
    (ite p t f = false) = ite p (t = false) (f = false) 
goal: ((if p then t else f) = false) = if p then t = false else f = false

full_name: Bool.not_ite_eq_true_eq_true
code: @[simp]
theorem not_ite_eq_true_eq_true (p : Prop) [h : Decidable p] (b c : Bool) :
  ¬(ite p (b = true) (c = true)) ↔ (ite p (b = false) (c = false)) 
goal: (¬if p then b = true else c = true) ↔ if p then b = false else c = false

full_name: Bool.not_ite_eq_false_eq_false
code: @[simp]
theorem not_ite_eq_false_eq_false (p : Prop) [h : Decidable p] (b c : Bool) :
  ¬(ite p (b = false) (c = false)) ↔ (ite p (b = true) (c = true)) 
goal: (¬if p then b = false else c = false) ↔ if p then b = true else c = true

full_name: Bool.not_ite_eq_true_eq_false
code: @[simp]
theorem not_ite_eq_true_eq_false (p : Prop) [h : Decidable p] (b c : Bool) :
  ¬(ite p (b = true) (c = false)) ↔ (ite p (b = false) (c = true)) 
goal: (¬if p then b = true else c = false) ↔ if p then b = false else c = true

full_name: Bool.not_ite_eq_false_eq_true
code: @[simp]
theorem not_ite_eq_false_eq_true (p : Prop) [h : Decidable p] (b c : Bool) :
  ¬(ite p (b = false) (c = true)) ↔ (ite p (b = true) (c = false)) 
goal: (¬if p then b = false else c = true) ↔ if p then b = true else c = false

full_name: Bool.eq_false_imp_eq_true
code: @[simp] theorem eq_false_imp_eq_true : ∀(b:Bool), (b = false → b = true) ↔ (b = true) 
goal: b = false → b = true ↔ b = true

full_name: Bool.eq_true_imp_eq_false
code: @[simp] theorem eq_true_imp_eq_false : ∀(b:Bool), (b = true → b = false) ↔ (b = false) 
goal: b = true → b = false ↔ b = false

full_name: Bool.cond_eq_ite
code: theorem cond_eq_ite {α} (b : Bool) (t e : α) : cond b t e = if b then t else e 
goal: (bif b then t else e) = if b = true then t else e

full_name: Bool.cond_eq_if
code: theorem cond_eq_if : (bif b then x else y) = (if b then x else y) 
goal: ∀ {α : Type u_1} {x y : α}, (bif b then x else y) = if b = true then x else y

full_name: Bool.cond_not
code: @[simp] theorem cond_not (b : Bool) (t e : α) : cond (!b) t e = cond b e t 
goal: (bif !b then t else e) = bif b then e else t

full_name: Bool.cond_self
code: @[simp] theorem cond_self (c : Bool) (t : α) : cond c t t = t 
goal: (bif c then t else t) = t

full_name: Bool.cond_decide
code: theorem cond_decide {α} (p : Prop) [Decidable p] (t e : α) :
    cond (decide p) t e = if p then t else e 
goal: (bif decide p then t else e) = if p then t else e

full_name: Bool.cond_eq_ite_iff
code: @[simp] theorem cond_eq_ite_iff (a : Bool) (p : Prop) [h : Decidable p] (x y u v : α) :
  (cond a x y = ite p u v) ↔ ite a x y = ite p u v 
goal: ((bif a then x else y) = if p then u else v) ↔ (if a = true then x else y) = if p then u else v

full_name: Bool.ite_eq_cond_iff
code: @[simp] theorem ite_eq_cond_iff (p : Prop) [h : Decidable p] (a : Bool) (x y u v : α) :
  (ite p x y = cond a u v) ↔ ite p x y = ite a u v 
goal: ((if p then x else y) = bif a then u else v) ↔ (if p then x else y) = if a = true then u else v

full_name: Bool.cond_eq_true_distrib
code: @[simp] theorem cond_eq_true_distrib : ∀(c t f : Bool),
    (cond c t f = true) = ite (c = true) (t = true) (f = true) 
goal: ((bif c then t else f) = true) = if c = true then t = true else f = true

full_name: Bool.cond_eq_false_distrib
code: @[simp] theorem cond_eq_false_distrib : ∀(c t f : Bool),
    (cond c t f = false) = ite (c = true) (t = false) (f = false) 
goal: ((bif c then t else f) = false) = if c = true then t = false else f = false

full_name: Bool.cond_true
code: protected theorem cond_true  {α : Type u} {a b : α} : cond true  a b = a 
goal: (bif true then a else b) = a

full_name: Bool.cond_false
code: protected theorem cond_false {α : Type u} {a b : α} : cond false a b = b 
goal: (bif false then a else b) = b

full_name: Bool.cond_true_left
code: @[simp] theorem cond_true_left   : ∀(c f : Bool), cond c true f  = ( c || f) 
goal: (bif c then true else f) = (c || f)

full_name: Bool.cond_false_left
code: @[simp] theorem cond_false_left  : ∀(c f : Bool), cond c false f = (!c && f) 
goal: (bif c then false else f) = (!c && f)

full_name: Bool.cond_true_right
code: @[simp] theorem cond_true_right  : ∀(c t : Bool), cond c t true  = (!c || t) 
goal: (bif c then t else true) = (!c || t)

full_name: Bool.cond_false_right
code: @[simp] theorem cond_false_right : ∀(c t : Bool), cond c t false = ( c && t) 
goal: (bif c then t else false) = (c && t)

full_name: Bool.cond_true_same
code: @[simp] theorem cond_true_same  : ∀(c b : Bool), cond c c b = (c || b) 
goal: (bif c then c else b) = (c || b)

full_name: Bool.cond_false_same
code: @[simp] theorem cond_false_same : ∀(c b : Bool), cond c b c = (c && b) 
goal: (bif c then b else c) = (c && b)

full_name: Bool.decide_coe
code: protected theorem decide_coe (b : Bool) [Decidable (b = true)] : decide (b = true) = b 
goal: decide (b = true) = b

full_name: Bool.decide_and
code: @[simp] theorem decide_and (p q : Prop) [dpq : Decidable (p ∧ q)] [dp : Decidable p] [dq : Decidable q] :
    decide (p ∧ q) = (p && q) 
goal: decide (p ∧ q) = (decide p && decide q)

full_name: Bool.decide_or
code: @[simp] theorem decide_or (p q : Prop) [dpq : Decidable (p ∨ q)] [dp : Decidable p] [dq : Decidable q] :
    decide (p ∨ q) = (p || q) 
goal: decide (p ∨ q) = (decide p || decide q)

full_name: Bool.decide_iff_dist
code: @[simp] theorem decide_iff_dist (p q : Prop) [dpq : Decidable (p ↔ q)] [dp : Decidable p] [dq : Decidable q] :
    decide (p ↔ q) = (decide p == decide q) 
goal: decide (p ↔ q) = (decide p == decide q)

full_name: false_eq_decide_iff
code: @[simp] theorem false_eq_decide_iff {p : Prop} [h : Decidable p] : false = decide p ↔ ¬p 
goal: false = decide p ↔ ¬p

full_name: true_eq_decide_iff
code: @[simp] theorem true_eq_decide_iff {p : Prop} [h : Decidable p] : true = decide p ↔ p 
goal: true = decide p ↔ p