Re: WISHLIST.TXT

new topic     » goto parent     » topic index » view thread      » older message » newer message

Derek <ddparnell at bigpond.com> wrote:

<snip>

> Thanks Matt. I proposed a statement that is similar to 'exit <name>'.

Very nice!

> I propose that we have a 'next <name>' statement. This would go to the
> *next* iteration of the named loop block.

Among all proposed keywords for this purpose (resume, iterate, continue)
"next" is the most intuitive for me.

>  Main:for j = 1 to 5 do
>    sum = 0
>    for i = 1 to 10
>      if sequence(x[j][i]) then
>         next Main
>      end if
>      if remainder(x[j][i],3) = 0 then
>        next
>      end if
>      sum += x[j][i]
>      printf(1, "%d is divisible by 3!\n", i)
>    end for
>    printf(1, "The sum is %d\n", sum)
>  end for

> ----------------
> cheers,
> Derek Parnell

Regards,
   Juergen

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu