Type in the words(s) to search for:

    Mark results
      Userbooster Help

      continue Statement

      Stops the current iteration of a loop and starts a new iteration.

      continue;

      Remarks

      The statement can only be used in while, do...while and for loops. On the continue, the script stops the current iteration of the loop and continues begins a new iteration of the loop. The execution of iteration is performed if:

      • the test condition of while or do...while is true.
      • the test expression of for is true.

      Example

      function function_returns_8()
      {
      var x = 3;
          for( i = 0; i < 10; i++ )
          {
              if( i < 5 )
                  continue;
              x++;
          }
          return x;
      }