A loop can be terminated within the body of its code sequence by the
execution of a break statement. In the following code fragment, for
example, the while loop executes until tries_cnt equals max_tries. If the
user guesses the correct answer, however, the loop is terminated using
the break statement:
參考答案:在循环的代码序列体之内通过执行 break 语句可以终止循环。比如在下列代码片断中,while 循环在 tries_cnt 等于 max_tries 之前保持执行。然而,如果用户猜到了正确的答案,就用 break 语句终止循环。