C++ | Function Overloading

Q.16.
Which function cannot be overloaded in C++ program?

a) Virtual function
b) member function
c) Static function
d) All can be overloaded

Q.17.
Choose the correct answer for the following piece of C++ code

void func(int a, int &b)
{

}
int main()
{
int a,b;
func(a,b);
}

a) a is pass by value and b is pass by reference
b) a is pass by reference and b is pass by value
c) a is pass by value and b is pass by address
c) a is pass by value and b is pass by pointer

Q.18.
Overloaded functions in C++ oops are

a) Functions preceding with virtual keywords.
b) Functions inherited from base class to derived class.
c) Two or more functions having same name but different number of parameters or type.
d) None of above

Q.19.
Which of the following function declaration using default arguments is correct?

a) int hello(int x, int y =5, int z=10)
b) int hello(int x=5, int y =10, int z)
c) int hello(int x=5, int y, int z=10)
d) all are correct