Question-41. Where an automatic variable is stored ?

Answer- Every local variable by default being an auto variable is stored in stack memory.

 

Question-42. What is a container class ?

Answer- A class containing at least one member variable of another class type in it is called so.

 

Question-43. What is a token ?

Answer- A C++ program consists of various tokens and a token is either a keyword, an identifier, a constant, a string literal, or a symbol.

 

Question-44. What is a preprocessors ?

Answer- Preprocessor is a directive to the compiler to perform certain things before the actual compilation process begins.

 

Question-45. What are the different ways of passing parameters to the functions? Which to use when?

Answer-

• Call by value: We send only values to the function as parameters. We choose this if we do not want the
 actual parameters to be modified with formal parameters but just used.
• Call by address: We send address of the actual parameters instead of values. We choose this if we do want 
the actual parameters to be modified with formal parameters.
• Call by reference: The actual parameters are received with the C++ new reference variables as formal 
parameters. We choose this if we do want the actual parameters to be modified with formal parameters.

 

Question-46. What is reminder for 5.0 % 2 ?

Answer- Error, It is invalid that either of the operands for the modulus operator (%) is a real number.

 

Question-47. Which compiler switch to be used for compiling the programs using math library with g++ compiler ?

Answer- Opiton –lm to be used as > g++ –lm

 

Question-48. What is recursion ?

Answer- Function calling itself is called as recursion.

 

Question-49. What is the maximum length of an identifier ?

Answer- Ideally it is 32 characters and also implementation dependent.

 

Question-50. What is the default function call method ?

Answer-By default the functions are called by value.