50+ Dynamic Array MCQs with FREE PDF

We have the best collection of the Dynamic Array MCQs and answer with FREE PDF. These Dynamic Array MCQs will help you to prepare for any competitive exams like: BCA, MCA, GATE, GRE, IES, PSC, UGC NET, DOEACC Exams at all levels – you just have to practice regularly.

Dynamic Array MCQs

1. In which of the following cases dynamic arrays are not preferred?

a) If the size of the array is unknown

b) If the size of the array changes after few iterations

c) If the memory reallocation takes more time i.e. expensive

d) If the array holds less number of elements

Answer: If the array holds less number of elements

2. In special case, the time complexity of inserting/deleting elements at the end of dynamic array is

a) O (n)

b) O (n1/2)

c) O (log n)

d) O (1)

Answer: O (n)

3. What is a dynamic array?

a) A variable size data structure

b) An array which is created at runtime

c) The memory to the array is allocated at runtime

d) An array which is reallocated everytime whenever new elements have to be added

Answer: A variable size data structure

4. What is meant by physical size in a dynamic array?

a) The size allocated to elements

b) The size extended to add new elements

c) The size of the underlying array at the back-end

d) The size visible to users

Answer: The size of the underlying array at the back-end

5. The number of items used by the dynamic array contents is its __________

a) Physical size

b) Capacity

c) Logical size

d) Random size

Answer: Logical size

6. How will you implement dynamic arrays in Java?

a) Set

b) Map

c) HashMap

d) List

Answer: List

7. Which of the following is the correct syntax to declare an ArrayList in Java?

a) ArrayList al = new ArrayList();

b) ArrayList al = new ArrayList[];

c) ArrayList al() = new ArrayList();

d) ArrayList al[] = new ArrayList[];

Answer: ArrayList al = new ArrayList();

8. Array is divided into two parts in ____________

a) Hashed Array Tree

b) Geometric Array

c) Bounded-size dynamic array

d) Sparse Array

Answer: Bounded-size dynamic array

9. Which of the following is a disadvantage of dynamic arrays?

a) Locality of reference

b) Data cache utilization

c) Random access

d) Memory leak

Answer: Memory leak

10. What is the time complexity for inserting/deleting at the beginning of the array?

a) O(1)

b) O(n)

c) O(logn)

d) O(nlogn)

Answer: O(n)

Also Read about Arrays Types

50+ Bit Array MCQs with FREE PDF
50+ Parallel Array MCQs with FREE PDF
50+ Sparse Array MCQs with FREE PDF
50+ Suffix Array MCQs with FREE PDF
50+ Matrix MCQs with FREE PDF
50+ Sparse Matrix MCQs with FREE PDF
50+ Count Inversion MCQs with FREE PDF
50+ Rotation Array Operation MCQs with FREE PDF
50+ Reversal Array Operation MCQs with FREE PDF
50+ Number of Jumps to Reach End-array Operation MCQs with FREE PDF

1000+ Data Structure MCQs

Abstract Data Types
Application of Stacks
Arrays Types
Types of Lists
Binary Trees
B-Trees
Trees
Heap
Trie
Hash Tables
Graph

Download PDF (Dynamic Array MCQs)

Comments