C and C++ has constructors and distructors, why does Java
does not have distructors?
Answer Posted / sandesh magdum
Because java has automatic garbage collection feature and java
does not let you illegally or accidentally release memory
occupied by an object.
| Is This Answer Correct ? | 7 Yes | 1 No |
Post New Answer View All Answers
what is daemon thread and which method is used to create the daemon thread? : Java thread
Explain java heap space and garbage collection?
What is parsing a sentence?
How do you achieve singleton?
Is zero a positive integer?
What is the common usage of serialization? What exceptions occur during serialization?
How can constructor chaining be done using this keyword?
What is array and arraylist in java?
What is the abstract class?
what is the constructor and how many types of constructors are used in java?
What does it mean to be immutable?
What do you mean by aggregation?
Write a program to show whether a graph is a tree or not using adjacency matrix.
What is an example of a keyword?
Can we create our own wrapper class in java?