Which of the following statements is correct about constructors?

Question:
Which of the following statements is correct about constructors?

1.If we provide a one-argument constructor then the compiler still provides a zero-argument constructor.

2.Static constructors can use optional arguments.

3.Overloaded constructors cannot use optional arguments.

4.If we do not provide a constructor, then the compiler provides a zero-argument constructor.

Posted Date:-2021-02-24 04:05:30


More MCQS Questions and answers

Search
R4R Team
R4Rin Top Tutorials are Core Java,Hibernate ,Spring,Sturts.The content on R4R.in website is done by expert team not only with the help of books but along with the strong professional knowledge in all context like coding,designing, marketing,etc!