what is constructer?what are the type of constructer with
example.

Answer Posted / sandesh nawadkar

Constructor is a same as method but it isnot exactly a
method . It has same name as a Class. It has access
specifier but not return type. Constructor is used to
create and initialize objects at runtime.
There are different types of constructors in different oop
languages.
e.g. Consider, java language-there are two types:-
1. Default
2. Parameterized.

Is This Answer Correct ?    12 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is resultsetmetadata in java?

520


How do I install jdk?

458


What is a singleton in java?

492


What is cloning in java?

493


How do I enable jvm?

468






What is entitymanager in jpa?

469


Java prints out a ton of digits when I system.out.println() a double. How can I format it so it displays only 3 digits after the decimal place?

469


How does jpa repository work?

510


What if I do not provide the string array as the argument to the method?

500


What is crud operations in java?

470


Is java installed on windows 10?

474


Describe the principles of oops.

498


What is flatmap java?

496


What are microservices in java?

459


What are tlds in java?

483