[metapost] short-circuit logic

Troy Henderson thenders at gmail.com
Thu Jun 23 00:33:11 CEST 2011


Does MetaPost have a short-circuit logical "or" and "and"?

That is, if a and b are booleans, and if a is false, then "a and b"
should evaluate to false independent of the value of b (and should not
even consider b).

Similarly, if a is true, then "a or b" should evaluate to true
independent of the value of b (and should not even consider b).

Troy


More information about the metapost mailing list