What is a method ?

Answer Posted / janet

Methods are functions that operate on instances of classes
in which they are defined.Objects can communicate with each
other using methods and can call methods in other
classes.Method definition has four parts. They are name of
the method,type of object or primitive type the method
returns,a list of parameters and the body of the method. A
method's signature is a combination of the first three
parts mentioned above.

Is This Answer Correct ?    1 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the difference between heap memory and stack memory?

593


What is an infinite loop? How infinite loop is declared?

545


What is the purpose of stub and skeleton?

520


What is the use of bufferedreader?

506


What is sortedset in java?

544






Explain the public class modifier?

479


What do you mean by ternary operator in java?

531


What is class level lock ?

594


Can we change the scope of the overridden method in the subclass?

814


How many arguments can a method have java?

518


What is the main functionality of the remote reference layer?

1388


Can we make main() thread as daemon?

557


How many java versions are there?

549


What are wrapper classes in java?

570


Is alive and join method in java?

511