Boolean values: Difference between revisions

Content added Content deleted
(Add min)
Line 1,184: Line 1,184:
Metafont has the type <tt>boolean</tt>; a boolean variable can be <tt>true</tt> or <tt>false</tt>.
Metafont has the type <tt>boolean</tt>; a boolean variable can be <tt>true</tt> or <tt>false</tt>.
Using non boolean values (or expressions that do not evaluate to a boolean value) results in a recoverable error; by default, any non-boolean value is interpreted as false.
Using non boolean values (or expressions that do not evaluate to a boolean value) results in a recoverable error; by default, any non-boolean value is interpreted as false.

=={{header|min}}==
{{works with|min|0.19.3}}
<code>true</code> and <code>false</code> are the only boolean values in min. The <code>bool</code> function converts various objects to boolean values:
*non-zero number: <code>true</code>
*zero number: <code>false</code>
*non-empty quotation: <code>true</code>
*empty quotation: <code>false</code>
*non-empty string: <code>true</code>
*empty string: <code>false</code>
*boolean: no conversion performed


=={{header|Mirah}}==
=={{header|Mirah}}==