Register Now

Login

Lost Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

What will be the output of the following JavaScript code?
var o = new F();
o.constructor === F

What will be the output of the following JavaScript code?
var o = new F();
o.constructor === F
a) false
b) true
c) 0
d) 1

Answer: b
Explanation: Constructor is a function property of the class which is used to create objects of that class. In the above code, both statements create an instance of the class.

Join The Discussion