-
Consider the following code snippet :
var tensquared = (function(n) {return n*n;}(100));
Will the above code work ?
-
- Memory leak
- Exception will be thrown
- Error
- Yes
- None of these
Correct Option: D
Function name is optional for functions defined as expressions. Function expressions are sometimes defined and immediately invoked.