What is operator overloading in Java with example?

Unlike C++, Java does not support user defined operator overloading. The overloading is done internally in java. We can take + (plus) for example: int a = 2 + 4; string = “hello” + “world”; Here, plus adds two integer numbers and concatenates two strings.8 Kas 2011

Sizin İçin Seçtik  What is meant by overloading a constructor?

Leave a Reply

Your email address will not be published. Required fields are marked *

What is operator overloading in Java with example?

Unlike C++, Java does not support user defined operator overloading. The overloading is done internally in java. We can take + (plus) for example: int a = 2 + 4; string = “hello” + “world”; Here, plus adds two integer numbers and concatenates two strings.8 Kas 2011

Sizin İçin Seçtik  What is method overloading?

Leave a Reply

Your email address will not be published. Required fields are marked *