Hi Lothar,<div><br></div><div>The if statement in Racket always requires three arguments:</div><div><br></div><div><span class="RktPn" style="font-family:monospace;white-space:nowrap;color:rgb(132,60,36);background-color:rgb(232,232,255)">(</span><a name="(form._((quote._~23~25kernel)._if))" style="font-family:serif;white-space:nowrap;background-color:rgb(232,232,255);font-size:medium"></a><span title="Provided from: racket/base, racket" style="font-family:serif;white-space:nowrap;background-color:rgb(232,232,255);font-size:medium"><span class="RktSym" style="font-family:monospace;white-space:inherit;color:rgb(38,38,128)"><a href="http://docs.racket-lang.org/reference/if.html?q=if&amp;q=mapcar&amp;q=map&amp;q=foldl&amp;q=take&amp;q=append*&amp;q=foldl&amp;q=number-%3E&amp;q=vector&amp;q=for/&amp;q=set#(form._((quote._~23~25kernel)._if))" class="RktStxLink" style="text-decoration:none;color:black">if</a></span></span><span class="hspace" style="font-family:monospace;white-space:nowrap;background-color:rgb(232,232,255)"> </span><span class="RktVar" style="font-family:monospace;white-space:nowrap;color:rgb(38,38,128);font-style:italic;background-color:rgb(232,232,255)">test-expr</span><span class="hspace" style="font-family:monospace;white-space:nowrap;background-color:rgb(232,232,255)"> </span><span class="RktVar" style="font-family:monospace;white-space:nowrap;color:rgb(38,38,128);font-style:italic;background-color:rgb(232,232,255)">then-expr</span><span class="hspace" style="font-family:monospace;white-space:nowrap;background-color:rgb(232,232,255)"> </span><span class="RktVar" style="font-family:monospace;white-space:nowrap;color:rgb(38,38,128);font-style:italic;background-color:rgb(232,232,255)">else-expr</span><span class="RktPn" style="font-family:monospace;white-space:nowrap;color:rgb(132,60,36);background-color:rgb(232,232,255)">)</span> </div>
<div><br></div><div>if you only want a &quot;then-expression&quot;, use &quot;when&quot; or &quot;unless&quot;
</div><div>if you want more expressions, use &quot;cond&quot;,  cond is a powerful and compact construct in Racket</div><div><br></div><div>-Joe<br><br><div class="gmail_quote">On Wed, Apr 11, 2012 at 11:42 AM, lothar atheling <span dir="ltr">&lt;<a href="mailto:lothar_@warpmail.net">lothar_@warpmail.net</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><br>
usually an (if ...) form without an else part does not cause an error.<br>
<br>
but sometimes it does, as the following shows:<br>
<br>
<br>
if: bad syntax (must have an &quot;else&quot; expression) in: (if isinitialised<br>
(expose))<br>
<br>
why the different behavior?<br>
<span class="HOEnZb"><font color="#888888"><br>
--<br>
<a href="http://www.fastmail.fm" target="_blank">http://www.fastmail.fm</a> - A fast, anti-spam email service.<br>
<br>
____________________<br>
  Racket Users list:<br>
  <a href="http://lists.racket-lang.org/users" target="_blank">http://lists.racket-lang.org/users</a><br>
</font></span></blockquote></div><br></div>