break only breaks out of the lowest loop you're in.
ex:
while(cond1)
{
doit1();
while(cond2)
{
doit2();
Type: Posts; User: helloworld922
break only breaks out of the lowest loop you're in.
ex:
while(cond1)
{
doit1();
while(cond2)
{
doit2();
Is there an easy way to do it? I want to break out of two loops, but the code is also in another loop.