Loops/While: Difference between revisions

Content added Content deleted
m (→‎{{header|REXX}}: changed condition to match task. -- ~~~~)
m (→‎{{header|REXX}}: showed J & X are both integers. -- ~~~~)
Line 879: Line 879:
===version 2===
===version 2===
<lang rexx>/*REXX program to show a DO WHILE construct. */
<lang rexx>/*REXX program to show a DO WHILE construct. */
j=1024
x=1024


do while j>0
do while x>0
say right(j,10)
say right(x,10)
j=j%2 /*in REXX, % is integer division. */
x=x%2 /*in REXX, % is integer division. */
end</lang>
end</lang>
'''output'''
'''output'''