Hard
Which statements are true about JavaScript Strict Mode?
Author: Jean-marie CléryStatus: PublishedQuestion passed 2282 times
Edit
2
Community Evaluations
Nguyen
09/05/2024
Among the statements you provided:
True: Strict Mode prohibits the use of octal notation on numbers. So, var a = 015; would indeed throw an error in Strict Mode.
True: Strict Mode improves the security of the eval() function by allocating a dedicated scope to it. This helps prevent unintended variable leaks.
True: Strict Mode forbids explicitly writing a variable in the window object. So, window.foo = 'bar'; would be disallowed in Strict Mode.
True: Strict Mode throws an error if semicolons are forgotten. It enforces stricter syntax rules.
7
Which of the following is the **most optimized** method for creating a literal object?6
What will this code display?5
What will be the first thing that the following code displays?5
How to call a function inside a function in Javascript7
Invert a string in Javascript8
Which of the following equality(s) are true? 0 == '', 'f' + 1 == 'f1'9
Write a Javascript code that prints the indexes of an array.