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 / nagaraj

it is an overriding because we are attempting to riding the already ride class(class B with class A)

Is This Answer Correct ?    2 Yes 11 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is static import in java?

534


Explain the overview of UDP messaging.

736


Why we cannot override static method?

561


What are the string methods in java?

584


Is array passed by reference in java?

582






Do I need java on my pc?

510


How many types of voids are there?

537


What is byte code and why is it important to java’s use for internet programming?

599


What is function and its uses?

570


what is the difference between process and thread? : Java thread

565


What do you understand by soft reference?

586


Can classes declared using the abstract keyword cab be instantiated?

562


How to compare two strings in java program?

675


If two threads have same priority which thread will be executed first ?

844


Compare overloading and overriding?

561