Answer Posted / shiva
java allows objects to initilize themselves when they are
created .this automatic initilization is done wih the use
of constructor .a constructor is a special type of method
that has the same name of its class.when ever an object of
class is created,its constructor will be invoked and it
will initilized the object.the return type for a
constructor is not defined as it implicitly takes its class
type as return type.
| Is This Answer Correct ? | 5 Yes | 5 No |
Post New Answer View All Answers
When is the finally clause of a try-catch-finally statement executed?
What is the purpose of the system class in java programming?
Explain access modifiers in java.
List the interfaces which extends collection interface?
Can we use string in switch case in java?
What is the basic concept of java?
Can constructor be static or final?
What is sortedmap in java?
Why is java multithreaded?
Is map sorted in java?
Is a copy constructor?
Explain reverse a linked list recursive java solution?
What is meant by string is immutable?
What is difference between static variable and global variable?
Is stringwriter thread safe?