What is the difference between overloading and overriding a
function?

Answer Posted / ankit

IN overloading the function are used in same class, they
have different parameters each time we define the funtion,
and perform the same task.

overriding is used in diferent class with same parameters.

Is This Answer Correct ?    2 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How does split work in java?

535


Can we have more than one package statement in the source file?

642


What are packages in java?

564


What is synchronization and why is it important in java programming?

469


If I don't provide any arguments on the command line, then what will the value stored in the string array passed into the main() method, empty or null?

712






What is queue in java?

554


Objects or references which of them gets garbage collected?

532


What is memory leak and how does java handle it?

523


What is the difference between jdk, jre, and jvm?

572


What is use of arraylist in java?

581


Can the interface be final?

580


What are the advantages of passing this into a method instead of the current class object itself?

1174


What is the importance of finally block in exception handling?

541


What is a lock or purpose of locks in java?

595


Is nan false?

535