image not found

Oops! That page can't be found.


Directions to Solve

Which of phrases given below each sentence should replace the phrase printed in bold type to make the grammatically correct? If the sentence is correct as it is, mark 'E' as the answer.

Q1: I have got some tea, but I do not have a sugar.

A some

B got

C any

D No correction required

E more

Q2: Is it true that a global variable may have several declarations, but only one definition?

A Yes

B No

Q3: Which of the following statement will be correct if the function has three arguments passed to it?

A All the argument will be the default argument.

B The first argument will be the default argument.

C The middle argument will be the default argument.

D The trailing argument will be the default argument.

Q4: Which of the following statement is incorrect?

A A function can have all its arguments as default.

B A default argument cannot be redefined in later declaration.

C Default argument cannot be provided for pointers to functions.

D Default arguments can be provided for pointers to functions.

Q5: Which of the following statement is correct?

A Constructors can have default parameters.

B Constructors cannot have more than one default parameter.

C Constructors cannot have default parameters.

D Constructors can have at most five default parameters.

Q6: Which of the following function / type of function cannot be overloaded?

A Virtual function

B Static function

C Both B and C

D Member function

Q7: Which of the following function declaration is/are incorrect?

A All are correct.

B int Sum(int a, int b = 2, int c = 3);

C int Sum(int a = 0, int b, int c = 3);

D Both B and C are incorrect.

E int Sum(int a = 5, int b);

Q8: Which of the following statement is incorrect?

A The default arguments are given in the function prototype and should be repeated in the function definition.

B The default value for an argument can be a global constant.

C Compiler uses the prototype information to build a call, not the function definition.

D The default arguments are given in the function prototype.

Q9: Where the default value of parameter have to be specified?

A Function definition

B Function call

C Function prototype

D Both B or C

Q10: Which of the following statement is correct?

A C++ allows the redefinition of a default parameter.

B Both A and B.

C C++ does not allow the redefinition of a default parameter.

D The default value for an argument cannot be function call.