Computer Science · Data Structures
Suppose an array is defined as a[] = {1, 2, 3, 4, 5} and there is a linked list whose nodes are defined as: struct node { int n; struct node *next; }; If the linked list also has 5 nodes, then which of the following statements is false?
- 1Both array and the linked list will have homogeneous data elements.
- 2To reach the i-th element of the linked list, it is necessary to traverse all the nodes before it, but not so for array elements.
- 3Both array 'a' and the linked list will occupy the exact same amount of memory space.✓
- 4Elements of array 'a' will be contiguous in memory but the nodes of the linked list will be non-contiguous.
Correct answer
Both array 'a' and the linked list will occupy the exact same amount of memory space.
Download Single Question PDF
Save this question and verified answer as a clean study sheet with live clickable link.
Share with Friends & Study Groups
Challenge your peer aspirants on WhatsApp or Telegram to solve this question!
Preparing for Computer Science?
Practice full-length mock tests with real exam timers, instant score analysis, and all-India ranking.
Want more practice questions on Data Structures?
Solve complete topic-wise tests with detailed solutions on GkGet.
Related Practice Questions
Recommended practice questions in Computer Science · Data Structures