Which constructor among the following will be called if a call is made like className(5,’a’);?
(a) className(int x=5,char c=’a’);
(b) int className(int x, char c, char d);
(c) className(int x, char c, int y);
(d) char className(char c,int x);
I got this question by my school principal while I was bunking the class.
The origin of the question is Constructors Overloading in section Default Arguments vs Overloading, Upcasting and Downcasting of Object Oriented Programming