UGC-NET | UGC NET CS 2016 July – III | Question 37
Implicit return type of a class constructor is:
(A) not of class type itself
(B) class type itself
(C) a destructor of class type
(D) a destructor not of class type
Explanation: Truly, constructor doesn’t have any return type not even void.
However, as the definition of Constructor goes, it is used to initialize an object of the class. So implicitly, they return the current instance of the class whose constructor it is.
Therefore, Implicit return type of a class constructor is class type itself.