Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
operators solution in Clear category for Boolean Algebra by Cjkjvfnby
from operator import and_, or_, xor, eq
def implication(x, y):
return not x or y
OPERATIONS = {"conjunction": and_,
"disjunction": or_,
"implication": implication,
"exclusive": xor,
"equivalence": eq}
def boolean(x, y, operation):
return OPERATIONS[operation](x, y)
Sept. 4, 2014
Comments: