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 / shrirang & chetak

yes, above program is overloading the disp() method

Is This Answer Correct ?    1 Yes 8 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Is a string literal?

525


What does the “static” keyword mean?

584


How to declare objects of a class ?

589


What is a class component?

615


What is command line argument in java?

608






How do you declare an array that will hold more than 64KB of data?

640


Explain about static imports in java?

598


What is indexof in java?

517


Why is it called a string?

567


Why method overriding is used?

541


Can you explain the usages of class.forname()?

611


What is difference between arraylist and list in java?

585


What is the use of callablestatement?

579


What are predefined functions?

578


What is the meaning of variables in research?

533