C# (pronounced C-sharp) is a new object oriented language from Microsoft and is derived from C and C++. It also borrows a lot of concepts from Java too including garbage collection.
C Sharp Interviews are getting tough these days as the technology grows faster. To get through the C Sharp interview one needs to update him/herself in a regular manner. Having said that, just before the interview, it is very important to have a quick glance of the reputed C Sharp questions and answers to make yourself comfortable during the interview process. This is where DoAnswers.com helps you in renewing yourself on C Sharp and various other technologies interview preparation.
41. What's the top .NET class that everything is derived from?
System.Object.
42. When do you absolutely have to declare a class as abstract?
1. When the class itself is inherited from an abstract class, but not all base abstract methods have been overridden. 2. When at least one of the methods in the class is abstract.
43. Who is a protected class-level variable available to?
It is available to any sub-class (a class inheriting this class).
44. Why can?t you specify the accessibility modifier for methods inside the interface?
They all must be public, and are therefore public by default.
45. Will the finally block get executed if an exception has not occurred?
Yes.