Operator overloading


#1

Can we have operator overloading in every language. I know how to achieve in C++, but is it supported in other languages too ?


#2

Yes, Operator overloading concept is present in other languages too.Some language allows defining new operators. Some languages restrict operator overloading to few operators.The complete list can be seen at the link https://en.wikipedia.org/wiki/Operator_overloading.


#3

Yes it will support in some other languages like python,…
In some languages it didn’t support user defined operator overloading For example, in Java it does not support , it will allow for some operator for built in type of variables.


#5

languages which supports operator overloading are:
c++, ruby, python, perl, c#,php, visual basic .net…etc

languages which does not support operator overloading are:
c, java, javascript, pascal, objective c … etc


#6

no we didn’t have operator overloading in C,java,js…
the languages which supports opertor overloading are c++,python,c#,.net…
so u can achieve operator overloading in c++,python…