In OverLoading concept,Why they are not consider return
value and why they are consider only parameters in method?
For ex: public int Add(int a,int b){...}
public String Add(int a,int b){...}



In OverLoading concept,Why they are not consider return value and why they are consider only param..

Answer / brunda r

Because, if at all the return value is same then compiler
should identify the functions by their parameters.

Is This Answer Correct ?    0 Yes 2 No

Post New Answer

More OOPS Interview Questions

Can a varargs method be overloaded?

0 Answers  


what is the application of oops?

8 Answers   IBM,


What does enum stand for?

0 Answers  


Name an advantage of array over linked list?

24 Answers   GML, IBM, Software Solutions,


What is polymorphism what are the different types of polymorphism?

0 Answers  


What is the point of polymorphism?

0 Answers  


We have a scale and 7 balls. 1 ball is heavier than all the rest. How to determine the heaviest ball with only 3 possible weighing attempts?

8 Answers   IBM, Sage, Vertex,


Write a program to find out the number of palindromes in a sentence.

1 Answers   TCS,


Write a java applet that computes and displays the squares of values between 25 and 1 inclusive and displays them in a TextArea box

0 Answers  


Can abstract class have normal methods?

0 Answers  


How to hide the base class functionality in Inheritance?

0 Answers   Viscus Infotech,


Which type does string inherit from?

0 Answers  


Categories