Calling a function inside another function

Notes:

Calling a function inside another function
If required we can call one function inside another function.

function h()
{
document.write(“h”,”<br/>”);
}
function g()
{
document.write(“g”,”<br/>”);
h();
}
function f()
{
document.write(“f”,”<br/>”);
g();
}
f();
Output:
f
g
h

Interview Questions: