Cpp Programming Quiz 165 – Which of the following statement will be correct if the function has three arguments passed to it?

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

[A]. The trailing 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]. All the argument will be the default argument.

Answer: Option A

Cpp Programming Quiz 166 – What will be the output of the following program?

Question: What will be the output of the following program?

#include
class IndiabixSample
{
public:
int a;
float b;
void BixFunction(int a, float b, float c = 100.0f)
{
cout<< a % 20 + c * --b; } }; int main() { IndiabixSample objBix; objBix.BixFunction(20, 2.000000f, 5.0f); return 0; }

[A].0
[B].5
[C].100
[D].-5

Answer: Option B

Cpp Programming Quiz 167 – Which of the following statement is correct?

Question: Which of the following statement is correct?
[A].Two functions having same number of argument, order and type of argument can be overloaded if both functions do not have any default argument.
[B].Overloaded function must have default arguments.[C].Overloaded function must have default arguments starting from the left of argument list.
[D]A function can be overloaded more than once.

Answer: Option D

Cpp Programming Quiz 169 – Which of the following statement is correct?

Question: Which of the following statement is correct?
[A]. Overloaded functions can have at most one default argument.
[B]. An overloaded function cannot have default argument.[C]. All arguments of an overloaded function can be default.
[D]. A function if overloaded more than once cannot have default argument.

Answer: Option C

Cpp Programming Quiz 171 – Which of the following statement is correct?

Question: Which of the following statement is correct?
[A].Overloaded functions can accept same number of arguments.
[B].Overloaded functions always return value of same data type.[C].Overloaded functions can accept only same number and same type of arguments.
[D].Overloaded functions can accept only different number and different type of arguments.

Answer: Option A