Rand Stats

Slang::Predicate

cpan:SAMGWISE

NAME

Slang::Predicate - Predicates in perl6

SYNOPSIS

use Slang::Predicate;

my (\α, \β) = (T, F);

say ((α → β) ∧ α) → β;

DESCRIPTION

Slang::Predicate adds operators common to predicate logic directly to perl6.

Exported terms and operators are:

TermsTermExample
TrueTT ~~ True
FalseFF ~~ False
InfixoperatorExample
TrueTT ~~ True
FalseFF ~~ False
DisjunctionT ∨ F ~~ True
ConjunctionT ∧ F ~~ False
Exclusive disjunction⊻ or ⊕T ⊻ F ~~ True
Conditional→ or ⇒ or ⊃T → F ~~ False
Biconditional↔ or ⇔ or ≡T ↔ F ~~ False
PrefixoperatorExample
Negation¬¬T ~~ False
Verum⊤F ~~ True
Falsum⊥T ~~ False

AUTHOR

Sam Gillespie samgwise@gmail.com

COPYRIGHT AND LICENSE

Copyright 2017 Sam Gillespie

This library is free software; you can redistribute it and/or modify it under the Artistic License 2.0.