Explain operator overloading.



Explain operator overloading...

Answer / Amar Singh

Operator overloading in C++ allows operators to be used with user-defined types (classes or structures) in the same way they are used with built-in types. This means that you can define how an operator behaves for a specific class or structure. For example, defining addition (+) for a complex number class.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More C++ General Interview Questions

What is difference between c++ and c ++ 14?

1 Answers  


What is void pointer in c++ with example?

1 Answers  


How do you remove an element from a set in c++?

1 Answers  


How are pointers type-cast?

1 Answers   iNautix,


What is enum c++?

1 Answers  


Is facebook written in c++?

1 Answers  


Write a program to show polymorphism in C++?

1 Answers   Impetus, Verifone,


How important is c++?

1 Answers  


What is tellg () in c++?

1 Answers  


Define virtual constructor.

1 Answers  


Can char be a number c++?

1 Answers  


What is the advantage of an external iterator.

1 Answers  


Categories