The constructor does not, in fact, return anything. You will not have a return type when declaring a constructor. Constructor is typically invoked implicitly during instantiation. Additionally, it serves only to initialize the instance variables; it is not a method.
Mercy Margret Answered question September 7, 2023
No, constructor does not return any value. While declaring a constructor you will not have anything like return type. In general, Constructor is implicitly called at the time of instantiation. And it is not a method, its sole purpose is to initialize the instance variables
brindha18 Answered question September 7, 2023