Question: what is difference between function declaration and function definition in javascript?
Answer: Declarations are loaded before any code can run. Function declarations load before any code is executed while Function expressions load only when the interpreter reaches that line of code. Similar to the var statement, function declarations are hoisted to the top of other code.