C#/.NET interview questions: - What is operator overloading? Mention differences between overloading and overriding?
- By Shiv Prasad Koirala in .Net
- Apr 3rd, 2014
- 147
- 0
Operator overloading is a concept of polymorphism where you can redefine operators like +, - , * etc with additional functionalities.
For instance we can redefine the + functionalities to add objects like obj1 + obj2. Below is simple code snippet which redefines + operator.

You can now use the + operator to add objects of type some class as shown in the below code snippet.

Differences between overloading and overriding
|
Overloading |
Overriding |
|
Overloading is a concept where we can have same method names with different input signature. |
In overriding we have a parent class with virtual functions which are overridden in the child classes. |
Also see the following .NET interview questions video on operator overloading in C# (Csharp): -
Shiv Prasad Koirala
Visit us @ www.questpond.com or call us at 022-66752917... read more
- By Shiv Prasad Koirala
- Jun 21st, 2013
- 2805
- 0
.NET interview questions 6th edition (Sixth edition) - By Shivprasad Koirala
- By Shiv Prasad Koirala
- Sep 12th, 2013
- 2244
- 0
What is Jquery ? ( ASP.NET Jquery interview questions with answers)
- By Shiv Prasad Koirala
- Mar 18th, 2014
- 362
- 0

