Java中使用什么关键字或函数来释放内存?
最佳答案
您不会在 Java 中释放内存。它是 garbage collected由 JVM。
Objects are created by Java's "new" operator, and memory for new objects is allocated on the heap at run time. Garbage collection is the process of automatically freeing objects that are no longer referenced by the program.
关于java - "__________ for Java"作为 "free in C"或 "delete in C++",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/3499937/