Differentiate constructor and a method and how are it be
used?

Answer Posted / arunji,shc

constructor it should be same name of class but method name
is userdefined.
when the object created constructor call automatically but
method through the object have to call.

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are the 3 types of loops in java?

721


What are keywords give examples?

794


What is the symbol for line break?

849


Can you use this() and super() both in a constructor?

730


What are namespaces in java?

731


What is the meaning of variable in research?

770


What is keyword and identifier?

874


What is the use of arrays tostring () in java?

738


What is difference between checked and unchecked exception in java?

800


can used Protected Class outside Function.?

827


What does index mean in java?

739


Where are variables stored?

743


What is a java string?

726


Which of the classes will have more memory allocated?

741


What is string and its types?

845