Share on Google+Share on Google+

Ragini Shukla
1 Answer(s)      9 years ago
Posted in : Java Beginners
View Answers

August 27, 2008 at 7:16 PM

Hi Ragini,

It is true that Java does not allow operator overloading. It is also true that an exception was made for String, although this is out of the control of developers as it is a built in feature of Java. Developers have no control over operator overloading in Java.

The designers of Java wanted to keep Java simple and found that operator overloading made code more complex and difficult to read. There are other methods available to achieve the same functionality as operator overloading, you could create methods in a class named plus(), minus(), multiply(), etc...





Related Tutorials/Questions & Answers:
java applets - Applet
java applets  hiiiii... i need ur help in usage of java code for navigation of one applet window to other...?? can you plz respond to me
String in Java - Java Beginners
String in Java  hiiiii i initialise a String array,str[] with a size. on beginning i dont know the actual requirement. on running i have to increase its size since it adds more elements to it. pls help me in it. thank
different type input in java
different type input in java  hiiiii... get input different different type like as DataInputStream,Scanner i want to get source code of these all type of input method. thank   Java Read through DataInputStream: import
"); //String s=request.getParameter("name"); //String r="hiiiii"+s
abt java - Java Beginners
abt java   hiiiii i m new to this language i have some problem with my java code ... i working on netbeans .. i write a code for user authetication ... in this code it take user name password and a user certificate(which


Advertisement null