C#.Net Interview Question and Answers

26. What is Jagged Arrays?
 
  • A jagged array is an array whose elements are arrays.
  • The elements of a jagged array can be of different dimensions and sizes.
  • A jagged array is sometimes called an array–of–arrays.
 
Your Name Your Email-ID
Your Answer
27. what is an abstract base class?
  An abstract class is a class that is designed to be specifically used as a base class. An abstract class contains at least one pure virtual function.
 
Your Name Your Email-ID
Your Answer
28. How is method overriding different from method overloading?
  When overriding a method, you change the behavior of the method for the derived class. Overloading a method simply involves having another method with the same name within the class.
 
Rajakumar, said Feb 10, 2014
In Method overloading the signature of function is changing by return type or number of parameter of type of parameter but function name is same. In Method overriding the signature of the function is same but functionality of method is change in the derived class.
Your Name Your Email-ID
Your Answer
29. What is the difference between ref & out parameters?
  An argument passed to a ref parameter must first be initialized. Compare this to an out parameter, whose argument does not have to be explicitly initialized before being passed to an out parameter.
 
Your Name Your Email-ID
Your Answer
30. What is the use of using statement in C#?
  The using statement is used to obtain a resource, execute a statement, and then dispose of that resource.
 
Your Name Your Email-ID
Your Answer