### Booleans
[
Datatype booleans Alias bools
Funcon true
Funcon false
Funcon not
Funcon implies
Funcon and
Funcon or
Funcon exclusive-or Alias xor
]
Datatype
booleans ::= true | false
Alias
bools = booleans
Funcon
not(_:booleans) : =>booleans
*/
Rule
not(false) ~> true
Rule
not(true) ~> false
Funcon
implies(_:booleans, _:booleans) : =>booleans
*/
Rule
implies(false, false) ~> true
Rule
implies(false, true) ~> true
Rule
implies(true, true) ~> true
Rule
implies(true, false) ~> false
Funcon
and(_:booleans*) : =>booleans
*/
Rule
and( ) ~> true
Rule
and(false, _*:booleans*) ~> false
Rule
and(true, B*:booleans*) ~> and(B*)
Funcon
or(_:booleans*) : =>booleans
*/
Rule
or( ) ~> false
Rule
or(true, _*:booleans*) ~> true
Rule
or(false, B*:booleans*) ~> or(B*)
Funcon
exclusive-or(_:booleans, _:booleans) : =>booleans
Alias
xor = exclusive-or
*/
Rule
exclusive-or(false, false) ~> false
Rule
exclusive-or(false, true) ~> true
Rule
exclusive-or(true, false) ~> true
Rule
exclusive-or(true, true) ~> false
/*
`not(B)` is logical negation.