Boolean values: Difference between revisions

Content deleted Content added
Eliasen (talk | contribs)
Frink
PureFox (talk | contribs)
Added Wren
Line 2,204:
 
The above prints "This is returned."
 
=={{header|Wren}}==
Wren has a core class, Bool, which has two instances ''true'' and ''false'' which are also ''reserved words'' in the language.
 
This class has two methods: the operator ''!'' which returns the logical complement of its receiver and ''toString'' which returns its string representation.
<lang ecmascript>var embed = true
System.printAll([embed, ", ", !embed, ", ", "Is Wren embeddable? " + embed.toString])</lang>
 
{{out}}
<pre>
true, false, Is Wren embeddable? true
</pre>
 
=={{header|XLISP}}==