Continue

来自YFRobotwiki
跳转至: 导航搜索

The continue statement skips the rest of the current iteration of a loop (do, for, or while). It continues by checking the conditional expression of the loop, and proceeding with any subsequent iterations.


示例


for (x = 0; x < 255; x ++)
{
    if (x > 40 && x < 120){      // create jump in values
        continue;
    }

    analogWrite(PWMpin, x);
    delay(50);
}




返回Arduino语法参考列表

更多建议和问题欢迎反馈至 YFRobot论坛