Computer Science, asked by svabunk18, 7 months ago

how can you create a memory leak in Java ​

Answers

Answered by Anonymous
2

Answer:

Plse mark me in brainlist ✏️

Explanation:

The standard definition of a memory leak is a scenario that occurs when objects are no longer being used by the application, but the Garbage Collector is unable to remove them from working memory – because they’re still being referenced. As a result, the application consumes more and more resources – which eventually leads to a fatal OutOfMemoryError.

For a better understanding of the concept, here’s a simple visual representation:

How memory leaks happen in Java

Similar questions