This is more from a general understanding of how memory works:
If the resources have not been deleted, you cannot use them because they are still busy. When resources are not disposed of / garbage collected / disposed of, they are not suitable for use, because there is something else using this memory. However, as soon as it goes out of scope, it must actually be destroyed. If this is not the case, then it is only in the JVM, which will lead to a memory leak .
For the second part, if you mean blocks of memory between elements, it all depends on whether there is enough space. Again, I'm not 100% about how the JVM manages memory, but if you need two blocks of memory, and there is only one block between Z1 and Z2 , then no, this will require space in memory.
Glenn nelson
source share