How do I negate values in Asymptote? I tried using not(true) but there does not seem to be an inbuilt not function for this.

Sure, I can define a function to do this, but I just want to know if there is standard way to do this in Asymptote

1 Answer 1


You're looking for the ! negation operator.

bool b = true; // b now equals true
b = !b;        // b now equal false

This operator and others can be found in section 6.9 of the documentation.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .