Break statement in switch statement
What does a break statement do in the switch statement?
Expert
Switch statement is the selection control statement that is used to handle multiple choices and transfer control to the case statements within its body. The following code snippet shows an example of the use of the switch statement in C#:
switch(choice) { case 1: console.WriteLine("First"); break; case 2: console.WriteLine("Second"); break; default: console.WriteLine("Wrong choice"); break; }
In switch statements, the break statement is used at the end of a case statement. The break statement is mandatory in C# and it avoids the fall through of one case statement to another.
Illustrate the difference between Web.Config and Machine.Config and where it will be?
What are the various ideas given by delegate? Describe in brief.
What do you understand by the JSON?
Define constant and variable.
Distinguish between read-only and constants variables which is used in the programs?
Differentiate between the HyperLink control and the LinkButton control?
Write the difference between globalization and localization?
Explain why SiteMapPath control is being referred as eyebrow or breadcrumb navigation control?
Name the events which occur when the client requests the ASP.NET page from IIS server?
Write the difference between Arrays and Collection?
18,76,764
1952887 Asked
3,689
Active Tutors
1432689
Questions Answered
Start Excelling in your courses, Ask an Expert and get answers for your homework and assignments!!