class A
{
public void disp(int a,int b)
{
System.out.println("hai");
}
}
class B
{
public void disp(int a,int b,int c)
{
System.out.println("hai");
}
}
above program is overloading or overriding?
Answer Posted / raji
class A and class B have same function name but different
arguments.overriding is possible only when both class A and
class B have same function name and same arguments.
| Is This Answer Correct ? | 7 Yes | 2 No |
Post New Answer View All Answers
What is thread life cycle?
What is nullpointerexception?
Objects or references which of them gets garbage collected?
What makes a function well defined?
Does anyone still use java?
What is use of arraylist in java?
What is the difference between an inner class and a sub-class?
What do you mean by object?
What is anonymous inner class?
What are passing parameters?
Can a abstract class be defined without any abstract methods?
What is the purpose of the enableevents() method in java programming?
Explain about java sdk?
Can there be an abstract method without an abstract class?
What is the base class of all exception classes in java?