C++ Interview Question and Answers

71. What are the types of storage qualifiers in C++?
 
    C++ includes three storage qualifiers:
  • Const : A const variable is one that the program may not modify except through initialiazation when the variable is declared.
  • Volatile: A volatile type qualifier tells the compiler that the program could change the variable.
  • Mutable: A const member function may modify a data member only if the data member is declared with the mutable qualifier.
 
Your Name Your Email-ID
Your Answer
72. What are the advantages of using on iterator?
  Iterator interfaces(API) are the same for all the containers. For example, a container list can internally have doubly linked list or singly list, but its corresponding iterator interface that is used to access its elements is always the same.
(iter->next)
 
Your Name Your Email-ID
Your Answer
73. What are data members?
  Data members are variables of any type(in-built or user defined).
 
Your Name Your Email-ID
Your Answer
74. What are the types of statements in c++?
 
    A program in any langauge basically consists of statements. Statements symbolize instructions. There are many categories of statements.
  • Expression statement
  • Assignment statement
  • Selection statement
  • Iteration statement
  • Jump statement
 
Your Name Your Email-ID
Your Answer
75. What is initialization?
  Initialization is a process of assigning a value to a variable at the time of declaration.
 
Karthikeyan R,says July 13,2017
Initialize a variable to any datatype then declare or initialize a numeric value or string
Your Name Your Email-ID
Your Answer