Oops interview questions and answers

In this blog, I have collected Interview questions and answers of OOPS (Object Oriented Programming System). Q. What are OOPS principals? Object oriented is an approach to do programming in C#, Java etc.OOPS Principals – 1. Abstraction2. Encapsulation3. Inheritance4. Polymorphism Q. Is inheritance possible if private constructor declared in paren class? Answer – No. Q. … Read more

State Management in C#

In my other blogs, you may read C# 6.0 new featuresIn this blog, I will explore about State Management in C#. If you have attended an interview as a C#.Net developer, then questions related to State Management is likely to be asked. You may read Important C# interview questions and answers What is State Management … Read more

What is collection in C#

Collection classes are used to store data of specific types. All types of collection support IEnumerable interface. Below are collection classes used in C#.net, all classes come under System.Collection namespace. List – An array does not allow dynamic resize, but a list allows dynamic size. Example: List<int> list = new List<int>(); list.Add(1); list.Add(5); list.Add(7); list.Add(10); … Read more

Exception handling in C#

Exception Handling in C#. Most .NET languages support exception handling. Essentially, when an error occurs in the application, the .NET Framework throws an exception that represents the problem. You can catch this object using an exception handler. If you fail to catch exception, code will be aborted, and the user will see an error message … Read more

Difference between interface and abstract class

Difference between abstract class and interface is one of the most asked question in interview.Lets have a look on difference between interface and abstract class.  Abstract Class vs Interface  Abstract classed can have implementation for some of its members, but interface can not have implementation of any members.  An interface can not contain fields but … Read more

Getting started with LINQ in C#

What is LINQ? LINQ stands for Language Integrated Query. LINQ defines keywords that you can use to select, filter, sort, group, and transform data. The minor miracle of LINQ is that different LINQ providers allow these keywords to work with different types of data. LINQ to Objects, LINQ to DataSet, LINQ to XML, LINQ to … Read more

Interface explained in easy steps

Interface is similar to a class but with only declaration and no definition. Below are few code to explain interface in easy steps. Interface member can not have definition. They have only declaration. interface ITest{void Method();} All members in interface are by default public. No need to add explicit accessmodifier. interface can not contain fields.In … Read more