Re: Well I did it! (variable_id, etc..)
- Posted by Patrick Barnes <mrtrick at gmail.com> Nov 26, 2004
- 672 views
On Thu, 25 Nov 2004 21:21:25 -0500, Greg Haberek <ghaberek at gmail.com> wrote: > P.S. I just added version() and now I'm working on a 'next' statement. > I think, due to the internal working of for and while loops, I'll have > to make 'next for' and 'next while' statements... or I need some way > of determining what type of loop i'm in. Well, what about if you are next'ing a for loop, you specify the variable of the loop you mean? I was thinking about this before, and it doesn't work too well for while loops, because there is no loop variable... That way, if there's no var, it's for a while loop, if there's a var, it's for a for loop? for a = 1 to 10 do for b = 1 to 200 do for c = 1 to 3 do if something(a,b,c) then next c --skips to the next iteration in the 'c' loop end if dostuff(b,a*c) if something_else(a,b,c) then next a --skips to the next iteration in the 'a' loop end if end for end for end for Looks pretty intuitive to me! -- MrTrick