Task

Write a    for    loop which writes a countdown from   10   to   0.



Related tasks

   Loop over multiple arrays simultaneously
   Loops/Break
   Loops/Continue
   Loops/Do-while
   Loops/Downward for
   Loops/For
   Loops/For with a specified step
   Loops/Foreach
   Loops/Increment loop index within loop body
   Loops/Infinite
   Loops/N plus one half
   Loops/Nested
   Loops/While
   Loops/with multiple ranges
   Loops/Wrong ranges


 
{def downward_for
 {lambda {:i}
   {if {< :i 0}
    then (end of loop)
    else :i {downward_for {- :i 1}}}}}
-> downward_for
 
{downward_for 10}
-> 10 9 8 7 6 5 4 3 2 1 0 (end of loop)
 