InterviewSolution
Saved Bookmarks
| 1. |
The lexical scooping in JavaScript is based on which of the following?(a) Segments(b) Blocks(c) Functions(d) Entire code |
|
Answer» Right option is (c) Functions To explain: Lexical scoping (sometimes known as static scoping) is a convention used with many programming languages that sets the scope (range of functionality) of a variable so that it may only be called (referenced) from within the block of code in which it is defined. JavaScript has lexical scoping based on functions but not blocks. |
|