File tree Expand file tree Collapse file tree 2 files changed +38
-1
lines changed Expand file tree Collapse file tree 2 files changed +38
-1
lines changed Original file line number Diff line number Diff line change 2020
2121- [ DOM Events] ( ./code-snippets/dom-events.md )
2222- [ Hoisting] ( ./code-snippets/hoisting.md )
23- - Scopes & Closures
23+ - [ Scopes & Closures] ( ./code-snippets/scopes&closures.md )
2424- Functions
2525- Objects
2626- Error handling
Original file line number Diff line number Diff line change @@ -38,5 +38,42 @@ const func = foo(7);
3838</details >
3939
4040</li >
41+
42+ ---
43+
44+ <li >
45+
46+
47+ ** What will be the output ?**
48+
49+ ``` JS
50+ const fn = () => {
51+ a = 2 ;
52+ console .log (a);
53+ }
54+
55+ fn ();
56+
57+
58+ ```
59+
60+ - A: ` undefined `
61+ - B: ` 2 `
62+ - C: ` Uncaught ReferenceError: a is not defined `
63+
64+ <br />
65+
66+ <details >
67+ <summary ><b >Answer</b ></summary >
68+ <p >
69+
70+ #### Option: B
71+
72+ </p >
73+ </details >
74+
75+
76+ </li >
77+
4178</ol >
4279
You can’t perform that action at this time.
0 commit comments