Category
Statements
Syntax
continue;
Description
Use the continue statement within loops to pass control to the end of the innermost enclosing end brace belonging to a looping construct, such as for or while; at which point the loop continuation condition is re-evaluated.
Example
This example illustrates the use of the keyword continue.
void __fastcall TForm1::Button1Click(TObject *Sender) { float array[20]; // Code to initialize array... for (int i = 0; i < 20; i++) { array[i] = random(i + 20); } array[6] = 0; for (int i = 0; i < 20; i++) { if (array[i] == 0) continue; array[i] = 1/array[i]; ListBox1->Items->Add(array[i]); } }
Copyright(C) 2008 CodeGear(TM). All Rights Reserved.
|
What do you think about this topic? Send feedback!
|