RosettaCodeData/Task/Loops-While/DUP/loops-while-2.dup
2023-07-01 13:44:08 -04:00

6 lines
245 B
Text

1024 {push 1024 on stack}
[ ][ ]# {while[condition>0][do]}
$ {DUP}
$. {DUP, print top of stack to STDOUT}
10, {print newline}
2/\% {2 DIV/MOD SWAP POP}