Sail E0 Webinar

MCQs

Total Questions : 147 | Page 7 of 15 pages
Question 61. In CPP, it is mandatory and must to initialize const variables.
  1.    True
  2.    False
 Discuss Question
Answer: Option A. -> True
NO EXPLANATION IS AVAILABLE FOR THIS QUESTION!
Question 62. Throwing an unhandled exception causes standard library function then _________ to be invoked.
  1.    stop()
  2.    aborted()
  3.    terminate()
  4.    Abandon()
 Discuss Question
Answer: Option C. -> terminate()
NO EXPLANATION IS AVAILABLE FOR THIS QUESTION!
Question 63. Which of the followings are false statements about Local class? 1. A local class type name can only be used in the enclosing function 2. All the methods of Local classes must be defined inside the class only 3. A Local class can contain static data members. 4. A Local class may contain static functions. 5. Non-static variables of the enclosing function are not accessible inside local classes. 6. Local classes cannot access global types, variables and functions.
  1.    Only 1,3
  2.    Only 3, 6
  3.    Only 2 , 4 , 6
  4.    None of these
 Discuss Question
Answer: Option B. -> Only 3, 6
NO EXPLANATION IS AVAILABLE FOR THIS QUESTION!
Question 64. When a class is defined inside any function or block, it is called ___________ .
  1.    Nested class
  2.    Block class
  3.    Local class
  4.    It is not possible
 Discuss Question
Answer: Option C. -> Local class
NO EXPLANATION IS AVAILABLE FOR THIS QUESTION!
Question 65. Due to ios::trunc mode, the file is truncated to zero length.
  1.    True
  2.    False
 Discuss Question
Answer: Option A. -> True
NO EXPLANATION IS AVAILABLE FOR THIS QUESTION!
Question 66. Default values for a function are specified when ____ .
  1.    function is defined
  2.    function is declared
  3.    Both a and b
  4.    None of these
 Discuss Question
Answer: Option B. -> function is declared
NO EXPLANATION IS AVAILABLE FOR THIS QUESTION!
Question 67. Can we write throw clause inside catch handler?
  1.    Yes
  2.    No
 Discuss Question
Answer: Option A. -> Yes
NO EXPLANATION IS AVAILABLE FOR THIS QUESTION!
Question 68. Return type of uncaught_exception() is ________________ .
  1.    int
  2.    bool
  3.    char *
  4.    double
 Discuss Question
Answer: Option B. -> bool
NO EXPLANATION IS AVAILABLE FOR THIS QUESTION!
Question 69. A const object of a class can call non-const member function of the class.
  1.    True
  2.    False
 Discuss Question
Answer: Option B. -> False
NO EXPLANATION IS AVAILABLE FOR THIS QUESTION!
Question 70. If an argument to a function is declared as const, then _______ .
  1.    function can modify the argument.
  2.    Function can’t modify the argument.
  3.    const argument to a function is not possible.
  4.    None of these
 Discuss Question
Answer: Option B. -> Function can’t modify the argument.
NO EXPLANATION IS AVAILABLE FOR THIS QUESTION!

Latest Videos

Latest Test Papers