What is Jump Constructs?

 Posted by Bhaskara on 5/5/2011 | Category: C# Interview questions | Views: 3063 | Points: 40
Answer:

The break statement causes an immediate exit from the for, switch, while statements.

example:

for(count=0;count<20;count++)

{
if(count==10)
{
break;
}
}


Asked In: Many Interviews | Alert Moderator 

Comments or Responses

Posted by: Shoeb2222 on: 6/22/2011 | Points: 10
The break statement takes the control out of for, switch, and while statements. If we use continue it break the current iteration and start from the next iteration.

Login to post response