Re: I miss loop



cj wrote:
When I'm inside a do while loop sometimes it's necessary to jump out
of the loop using exit do. I'm also used to being able to jump back
and begin the loop again. Not sure which language my memories are of
but I think I just said loop somewhere inside the loop and it
immediately jumped back to the start of the loop and began again. I
can't seem to do that in .net. I this functionality available?

The meaning of "continue" is to start the *next* iteration immediately and
bypass any further code in the loop body. If you want to continue the
current operation then you'd either have an inner loop or use a goto. If you
want to completely restart the loop then you'd be best enclosing it in an
outer loop. You mustn't use the goto idea for that one. Jumping out of the
loop to before the loop - that should get you those frowns. ;o)



.



Relevant Pages

  • Re: Letter to US Sen. Byron Dorgan re unpaid overtime
    ... >> considered to be a convenience by those who use the C language. ... I make no claims to being a VB.NET programmer. ... Ritchie SCREWED UP in designing the for loop because ... I do not believe that you are capable of writing a conforming C compiler. ...
    (comp.programming)
  • Re: Letter to US Sen. Byron Dorgan re unpaid overtime
    ... > Hey, idiot, read my lips - the CONDITION is evaluated before each loop ... expressed my hope that you actually know the sequence of evaluations ... inappropriately with commercial promotion of the C language when I ... Programming Style: code what you mean. ...
    (comp.programming)
  • Re: Program compression
    ... RH> which is a one-liner in pretty well any language. ... PJB> Not in languages that don't provide syntactic abstraction. ... ;Return list of such SUBSEQ forms. ... loop at all, just inline machine instructions to call SUBSEQ just ...
    (comp.programming)
  • Re: GSoft BASIC Ramble
    ... I hate "goto" - sign. ... Pascal class - use a repeat/while loop with a boolean flag... ... But why did Pascal, the ultimate structured programming language, ...
    (comp.sys.apple2)
  • Re: Why does returning from a block cause a LocalJumpError
    ... If I understand correctly, even though b is defined inside the loop, a ... and b are both stored in the same stack frame when this method is ... I see your logic -- you're trying to look at how the language runtime ... Maybe I'm perseverating on this point, but I'm curious about how Ruby ...
    (comp.lang.ruby)

Loading