1.break and Continue.
These two keywords are generally used in loops of curly braces.
break--ends the entire loop.
continue--ends the cycle and enters the next cycle.
2.while Cycle
Initial
while (loop condition)
{
Loop body
Change Status to
}
int i = 1;
int count=0; Record the number of numbers associated with 7
while (i<=100)
{
if (i%7==0 | | i%10==7| | I/10==7)
{
Console.Write (i+ "\ t");
count++;
}
i++;
}
Console.Write ("A total of" +count+ "with 7 related numbers");
3.do...while (circular condition) simple to understand.
The loop is executed once even if the initial conditions do not meet the loop condition.
Execute at least once.
Arrays: The ability to solve the same class of large amounts of data stored and operated in memory.
Categories: one-dimensional arrays, two-dimensional arrays, multidimensional arrays.
Features: continuous, same class of data.
Break continue.