1.

The JavaScript classes can be instantiated using _____ operator.(a) create(b) new(c) instantiate(d) create.newThis question was posed to me in an internship interview.The doubt is from Scripting Java with Rhino topic in chapter Server-Side and Client-Side Scripting of JavaScript

Answer»

The correct answer is (B) new

For explanation I would say: New is a KEYWORD in JavaScript which is used to DEFINE new models. New operator is used to create new instance of the CLASS.



Discussion

No Comment Found

Related InterviewSolutions