Method Definition

Method Definition

A method must be defined before it is used anywhere in the program. The general form of method definition consist of two parts.

Method Header/prototype

Body of method

Method Header

A method header/prototype is the first line of method definition that tells the compiler about the method name, type of value returned by the method, and the types of arguments to be passed, if the function is expected to return  some result, then the function prototype reveals the data type of the result.

Java : Method Definition Program List

Program [1]

Write java Function to check number is prime or not using function

View Solution

CCC Online Test 2021 CCC Practice Test Hindi Python Programming Tutorials Best Computer Training Institute in Prayagraj (Allahabad) Best Java Training Institute in Prayagraj (Allahabad) Best Python Training Institute in Prayagraj (Allahabad) O Level NIELIT Study material and Quiz Bank SSC Railway TET UPTET Question Bank career counselling in allahabad Sarkari Naukari Notification Best Website and Software Company in Allahabad Website development Company in Allahabad