Final Term

All A template function must have at least ---------- generic data type

A.  Zero B.  


C.  Two D.  Three

Which of the following statement is best regarding declaration of friend function?

A.  Friend function must be declared after public keyword . B.  Friend function must be declared after private keyword. C.  Friend function must be declared at the top within class definition. D.  

It can be declared anywhere in class as these are not affected by the public and private keywords.

3. Which one of the following is the declaration of overloaded pre-increment operator implemented as member function?
A.  Class-name operator +() ; B.  Class-name operator +(int) ; C.  

Class-name operator ++() ;

D.  Class-name operator ++(int) ;
4. Class is a user defined___________.

data type

B.  memory referee C.  value D.  none of the given options.

How many bytes will the pointer intPtr of type int move in the following statement? intPtr += 3 ;

A.  3 bytes B.  6 bytes C.  12 bytes D.  24 bytes

Which of the following is the correct C++ syntax to allocate space dynamically for an array of 10 int?

A.  new int(10) ; B.  new int[10] ; C.  int new(10) ; D.  int new[10];
7. A Pointer is a special variable that contain
A.  Data values B.  

Memory Address 

C.  Both data and values D.  None of the given option
8. When a value is referred by a normal variable then it is known as,

Direct Reference

B.  Indirect Reference. C.  

Partial Reference


Proper Reference


Which of the following function is used to increase the size of already allocated memory chunk?

A.  malloc B.  calloc C.  


D.  free
10. Which of the following is NOT a preprocessor directive?
A.  #error B.  #define C.  #line D.