Computer Science, asked by amansaraswat8206, 11 months ago

Differentiate between static and dynamic memory allocation

Answers

Answered by ManyaSingh13
0

Answer:

Explanation:

Static memory is allocated on stack, while dynamic memory is allocated on heap. Dynamic memory needs to be manually release after use, while static memory is released itself once the binding variable scope is over. Use malloc() or calloc() for dynamic memory allocation and free() for releasing the memory in C.

Attachments:
Similar questions