javaScript functions are block of statement which are used to perform various task according to the requirement. Functions will be executed if and only if, when someone invoked them.
Functions
javaScript functions are block of statement which are used to perform various task according to the requirement. Functions will be executed if and only if, when someone invoked them.
Syntax
javaScript functions define by using function keyword ,followed by name . Function names can be letters,digits etc. Functions can contain parameters as well . Functions always start's and end with {}.function functionName(parameter1,parameter2,etc)
{
//function body
}