天天看点

JavaScript -- 标签 , Break 和 Continue 语句

break 语句用于跳出循环。

continue 用于跳过循环中的一个迭代。

标签引用,break 语句可用于跳出任何 JavaScript 代码块。

demo:

对应的Js代码:

继续阅读