| title | continue (C# Reference) | ||
|---|---|---|---|
| ms.date | 07/20/2015 | ||
| ms.prod | .net | ||
| ms.technology |
|
||
| ms.topic | article | ||
| f1_keywords |
|
||
| helpviewer_keywords |
|
||
| ms.assetid | 8a5ac96f-f98a-4519-b32d-345847ed7be0 | ||
| caps.latest.revision | 20 | ||
| author | BillWagner | ||
| ms.author | wiwagn |
The continue statement passes control to the next iteration of the enclosing while, do, for, or foreach statement in which it appears.
In this example, a counter is initialized to count from 1 to 10. By using the continue statement in conjunction with the expression (i < 9), the statements between continue and the end of the for body are skipped.
[!code-csharpcsrefKeywordsJump#3]
[!INCLUDECSharplangspec]
C# Reference
C# Programming Guide
C# Keywords
break Statement
Jump Statements