Click here to Skip to main content
15,895,746 members
Please Sign up or sign in to vote.
1.00/5 (3 votes)
See more:
I need clear related answer plz help me
Posted
Comments
E.F. Nijboer 3-Apr-15 5:43am    
School assignment? Try google first. If something then still is unclear you can ask a specific question about it here. This question is too general and clearly you haven't put any effort in it. I put more effort in this comment!

I'm citing from this article: A Beginner's Tutorial on Operator Overloading in C#[^]:

"In an object oriented programming language like C#, operator overloading provides a much more natural way of implementing the operations on custom types. Suppose that we have a class created for Complex number and we want to perform all the arithmetic operations on this type. One way to do this is by having functions like Add, Subtract inside the class and have the functionality. Another way is to actually have the overloaded version of operators to act on this type."

Please refer to the article for further information and how to actually implement operator overloading.
 
Share this answer
 
There are many nice articles like below. Read them and do some research.
1. A Beginner's Tutorial on Operator Overloading in C#[^]
2. An Introduction to Operator Overloading in C#[^]
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900