Difference between break and continue in PHP?

后端 未结 10 2438
粉色の甜心
粉色の甜心 2020-12-02 05:02

What is the difference between break and continue in PHP?

10条回答
  •  無奈伤痛
    2020-12-02 06:01

    break will stop the current loop (or pass an integer to tell it how many loops to break from).

    continue will stop the current iteration and start the next one.

提交回复
热议问题