Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
one line solution in Clear category for Boolean Algebra by kazuki.h
OPERATION_NAMES = {"conjunction": lambda x, y: x and y,
"disjunction": lambda x, y: x or y,
"implication": lambda x, y: not x or y,
"exclusive": lambda x, y: x ^ y,
"equivalence": lambda x, y: x == y}
def boolean(x, y, operation):
return OPERATION_NAMES[operation](x, y)
April 3, 2021
Comments: