Learn Shadowing In JavaScript Day 4
Lecture 4 : Learn Shadowing In JavaScript Shadowing Problem : Shadowing is an informal way for someone to learn what it is like to perform a particular job at a workplace. An individual follows around, or shadow, the worker already in that role. Shadowing is not restricted to individuals who are new to the professional workforce, as it can be an equally useful tool for those in established careers who are looking to pivot to new directions. There are two concepts of Shadowing: 1) Variable Shadowing 2) Function Shadowing Outer variable or function is shadowed by the inner variable or function. Inner variable or function is mask of outer variable or function. Example : Program- <html> <body> <script> function fun() { var f1 = 10; alert(f1); } function fun() { var f2 = 20; alert(f2); } fun(); <...