2014-01-05 20:05:08 +00:00
|
|
|
definition xor (x y : Bool) : Bool := (not x) = y
|
|
|
|
infixr 50 ⊕ : xor
|
2014-01-05 19:03:35 +00:00
|
|
|
print xor true false
|
2014-01-05 20:05:08 +00:00
|
|
|
eval xor true true
|
|
|
|
eval xor true false
|
|
|
|
variable a : Bool
|
2014-01-05 19:03:35 +00:00
|
|
|
print a ⊕ a ⊕ a
|
2014-01-06 03:10:21 +00:00
|
|
|
check @subst
|
2014-01-05 20:05:08 +00:00
|
|
|
theorem EM2 (a : Bool) : a \/ (not a) :=
|
2014-01-06 03:10:21 +00:00
|
|
|
case (fun x : Bool, x \/ (not x)) trivial trivial a
|
2014-01-05 20:05:08 +00:00
|
|
|
check EM2
|
|
|
|
check EM2 a
|