Sail E0 Webinar

MCQs

Total Questions : 67 | Page 2 of 7 pages
Question 11. The four kinds of class members are
  1.    Instance methods, Instance fields, Static method, Dynamic method
  2.    Instance fields, Instance methods, Class fields, Class methods
  3.    Instance fields, Non-instance fields, Dynamic methods, Global methods
  4.    Global methods, Local methods, Dynamic methods, Static methods
 Discuss Question
Answer: Option B. -> Instance fields, Instance methods, Class fields, Class methods
Question 12. The object whose properties are inherited by all instances of the class, and properties whose values are functions behaving like instance methods of the class, is
  1.    Instance object
  2.    Constructor object
  3.    Destructor object
  4.    Prototype object
 Discuss Question
Answer: Option D. -> Prototype object
Question 13. The properties of the objects act like different kinds of class members. They are
  1.    Public object, Private object, Protected object
  2.    Constructor object, Function object, Destructor object
  3.    Constructor object, Prototype object, Instance object
  4.    Instance method, Static object, Dynamic object
 Discuss Question
Answer: Option C. -> Constructor object, Prototype object, Instance object
Question 14. The class that represents the regular expressions is
  1.    RegExpObj
  2.    RegExpClass
  3.    RegExp
  4.    StringExp
 Discuss Question
Answer: Option C. -> RegExp
Question 15. Which are usually variables that are used internally in object methods and also are globally visible variables?
  1.    Object properties
  2.    Variable properties
  3.    Method properties
  4.    Internal properties
 Discuss Question
Answer: Option B. -> Variable properties
Question 16. Which is the correct code that returns a complex number that is the complex conjugate of this one?
  1.    Complex.prototype.conj = function() { return new Complex(this.r, -this.i); };
  2.    Complex.prototype.conj = function() { return Complex(this.r, -this.i); };
  3.    Complex.prototype.conj = function() { return (this.r, -this.i); };
  4.    Complex.prototype.conj = function() { new Complex(this.r, -this.i); };
 Discuss Question
Answer: Option A. -> Complex.prototype.conj = function() { return new Complex(this.r, -this.i); };
Question 17. How can we make methods available on all objects?
  1.    Object.add(methods)
  2.    Object.methods(add)
  3.    Object.add.methods(…)
  4.    Object.prototype
 Discuss Question
Answer: Option D. -> Object.prototype
Question 18. What is the procedure to add methods to HTMLElement so that they will be inherited by the objects that represent the HTML tags in the current document?
  1.    HTMLElement.prototype(…)
  2.    HTMLElement.prototype
  3.    HTML.addmethods()
  4.    HTML.elements(add)
 Discuss Question
Answer: Option B. -> HTMLElement.prototype
Question 19. You can refresh the webpage in JavaScript by using
  1.    window.reload
  2.    location.reload
  3.    window.refresh
  4.    page.refresh
 Discuss Question
Answer: Option B. -> location.reload
Question 20. The functions provide() and require() of Dojo toolkit and Google’s Closure library are used for
  1.    declaring and loading modules
  2.    loading and declaring modules
  3.    declaring modules
  4.    none of the mentioned
 Discuss Question
Answer: Option A. -> declaring and loading modules

Latest Videos

Latest Test Papers