RosettaCodeData/Task/Logical-operations/Maxima/logical-operations.maxima

10 lines
219 B
Plaintext

f(a, b) := [not a, a or b, a and b];
/* to use multiple arguments, use any of these */
a and b and c and d;
a or b or c or d;
"and"(a, b, c, d);
"or"(a, b, c, d);
apply("and", [a, b, c, d]);
apply("or", [a, b, c, d]);