A memory leak may occur when: (1 point) Responses a heap gets too large. a heap gets too large. a heap gets too small. a heap gets too small. a stack gets too large. a stack gets too large. a stack gets too small.

1 answer

A memory leak typically occurs when a program allocates memory on the heap but fails to release it back after it is no longer needed, causing the heap to grow excessively large. Therefore, the correct response is:

  • a heap gets too large.