+1 vote
in Data Structures & Algorithms I by (110k points)
Which of the following is a disadvantage of dynamic arrays?

(a) Locality of reference

(b) Data cache utilization

(c) Random access

(d) Memory leak

I'd like to ask this question from Dynamic Array in chapter Arrays Types of Data Structures & Algorithms I

I have been asked this question in an interview for job.

1 Answer

+1 vote
by (408k points)
selected by
Best answer
Right answer is (d) Memory leak

Explanation: Dynamic arrays share the advantage of arrays, added to it is the dynamic addition of elements to the array. Memory can be leaked if it is not handled properly during allocation and deallocation. It is a disadvantage.

Related questions

Welcome to TalkJarvis QnA, a question-answer community website for the people by the people. On TalkJarvis QnA you can ask your doubts, curiosity, questions and whatever going in your mind either related to studies or others. Experts and people from different fields will answer.