Basics of Functions in JS
A function is defined with the function keyword followed by its name and parentheses. It is a block of code designed to perform a particular task. A function can be executed when you invoke or call it any time you want. You cannot execute a function by just defining it. For executing a function you need to invoke (call) a function. The return value is stored in the calling function. You can log the value to the console by calling a function and log it to the same place.
I m a self learnt Node JS Developer from India.
Join Hacker Noon
Create your free account to unlock your custom reading experience.