Use the BREAK statement intelligently to jump out of this layer loop, but sometimes you want to jump out two or more loops how to deal with? I think there are two ways. The first way is to use a goto statement, such a large-scale transfer, how many layers of cycles are jumped out. But well known, GOTO statement is conflicted by most programmers because it violates structured? Second, I want to make a bit more troublesome, it is to set a flag before jump out (for example, give a BOOL type variable Flag assignment), then judge in the second layer loop, select the second layer loop or continue Execute the second layer. However, the disadvantage of this is that if you want to jump out of the multi-layer loop, you may need multiple flag variables. You can solve the problem in most of you only need a FLAG. How to choose these two methods will have the situation. I don't know if there is any other way.