Wednesday, September 25, 2013

Part 4: C#.Net interview questions and answers

Part 1 - C#.Net interview questions and answers

Part 1 - C#.Net interview questions and answers

Part 3 - C#.Net interview questions and answers

Part 5 - C#.Net interview questions and answers


50.       Can you override private virtual methods?

51.       What is dispose methods in .Net?

52.       What is the use of Dispose method?

53.       How to force dispose method to call automatically?

54.       What is significance of Finalize method in .Net?

55.       How can we suppress finalize method in .Net?

56.       What is Garbage collector?

57.       What is difference between system.string Vs system.stringbuilder?

58.       Interview questions related to constructor and destructor
a)      What is constructor in .Net?
b)      What is destructor in .Net
c)       What are types of constructor? Static and dynamic constructor?
d)      How many constructor's and destructor are allowed in program?
e)      When constructor and destructor are called?
f)       When should we use constructor and destructor? 
g)      What are the advantages and disadvantages of it?
h)      For below code which constructor will fire first?
i)        In what instances you will declare constructor to be private?


59.       Interview questions on Error handling in C#
a)       Can we have try block with finally block without having catch block?
b)       Can we have try block without having catch block and finally block?
c)       What are exceptions?
d)      What are the 3 approaches to handle exceptions in a Web application?
e)      Where will the control flow if an exception occurs inside a try block?
f)       Will the finally block gets executed, if an exception occurs? 
g)    Will finally block get executed if the exception had not occurred
h)    How do you raise expection?
i)     What are Error Events?
k)   Give an example to show how error events can be used to handle exceptions?

60.       What is Extension Methods in C#, how to create it and Advantages of it?

61.       What is Typed Object in C#, Example, Advantages and disadvantages of it?

62.       Nullable Types in C#, Advantages, Disadvantages.

63.       Anonymous types in C#, Advantages.

64.       What's the difference between IEnumerable<T> and List<T> ?

65.       IEnumerable Vs IQueriable?

66.       Boxing and Unboxing?

67.       Bool Vs Boolean


2 comments: