Advertisement Remove all ads

How linked list are represented in Memory ? - Computer Science 1

How linked list are represented in Memory ?

Advertisement Remove all ads

Solution

(1) Linked lists can be represented in memory by using two arrays respectively known as INFO and LINK, such that INFO[K] and LINK[K] contains information of element and next node address respectively.
(2) The list also requires a variable ‘Name’ or ‘Start’, which contains address of first node. Pointer field of last node denoted by NULL which indicates the end of list. e.g., Consider a linked list given below :

(3) The linked list can be represented in memory as -

Above figure shows linked list. It indicates that the node of a list need not occupy adjacent elements in the array INFO and LINK.

Concept: Basic Data Structures (Stack, Queue, Dequeue)
  Is there an error in this question or solution?
Advertisement Remove all ads

APPEARS IN

Advertisement Remove all ads
Advertisement Remove all ads
Share
Notifications

View all notifications


      Forgot password?
View in app×