Loops/While: Difference between revisions

Content added Content deleted
Line 1,954: Line 1,954:


=={{header|XLISP}}==
=={{header|XLISP}}==
The specification calls for an integer value and for the loop to run <tt>WHILE</tt> that value is greater than zero. In a dynamically typed language like XLISP, variables cannot be declared as integer or real; but the same result is obtained by looping <tt>WHILE</tt> the value of the variable <i>i</i> is greater than or equal to one.
<lang xlisp>(DEFINE I 1024)
<lang xlisp>(DEFINE I 1024)