Explain role of constructor in a java application?
Answer Posted / sonal
Without a constructor u cannot make an object or instance
of a class.
Every class must have a constructor. If no constructor is
provided the complier will provide default constructor at
run time.
| Is This Answer Correct ? | 33 Yes | 2 No |
Post New Answer View All Answers
What is supplier in java?
What are internal variables?
Similarity and difference between static block and static method ?
What is the formula to calculate percentage?
Explain the use of sublass in a java program?
What is the basic difference between string and stringbuffer object?
Is null == null in java?
Is it necessary that each try block must be followed by a catch block?
What do you mean by global variable?
What are basic keywords?
How is garbage collection controlled?
What is yield () in java?
What is the difference between equals() and?
What is the difference between the paint() and repaint() methods in java programming?
Can constructor be synchronized?