the value of this. They are very useful to use this appropriately and in many other scenarios like Function Borrowing,
call() method is used to invoke the function, it will pass an object as first parameter which will be the value of this inside
functionName.call(objectName, param1, param2,...);
apply() method is same as call(). It is used to invoke the function but the parameters will be passed in array. This may be
very useful in scenarios where we get the input in form of array or we have to pass variable number of arguments.
functionName.apply(objectName, [param1, param2,...]);
bind() is used to create new function, it will pass an object as parameter which will be the value of this inside function.
var bFunction = functionName.bind(objectName);
Suresh Kumar Srivastava is founder of online learning site coursegalaxy.com and author of popular books "C In Depth",
"Data Structures Through C In Depth". He has 18+ years experience in industry and worked on architecture and design of