C# Control Statements and Expressions Interview Questions - 1
What is called compound statement?
A group of statements enclosed within the curly braces comprises a block. It is also known as compound statement.
What is the use of lock statement?
The lock statement is used to implement the mechanism of mutual exclusion of critical sections.
An object is locked until it completes the execution of its embedded statement and then the lock is released.
What is called fall through in C#?
In the absence of the break statement in a case block, and the control move to the next case block without any problem then it is called as fall through.
C# does not permit the fall through. Where as C, C++, Java permits.
What is for each statement in C#?
The for each statement is similar to the for statement but implemented differently.
It is used to enumerate the contents of a collection such as array, list, and hash table.
100+ Data Interpretation Pie Chart Questions and Answers More
True Discount Questions and Answers for Bank Exams More
100+ HCF and LCM Questions and Answers for SSC Exams More
Aptitude Interview Questions and Answers Pdf More
100+ Boats and Streams Problems with Solutions Pdf More
Double Analogy Verbal Reasoning Questions and Answers More
Top 100+ Electric Current and Its Effects Quiz Questions & Answers More
Famous Personalities Quiz Questions and Answers 2020-2021 More
Top 200+ C++ Interview Questions and Answers More
Important Days Online Test 2019-2020 More