Assertion A: It is possible to create doubly linked list using only one…

2023

Assertion A: It is possible to create doubly linked list using only one pointer with every node

Reason R: By storing the XOR of the addresses of the previous and next nodes

In the light of the above statements, choose the most appropriate answer

  1. A.

    Both A and R are true and R is the correct explanation of A

  2. B.

    Both A and R are true but R is not the correct explanation of A

  3. C.

    A is true but R is false

  4. D.

    A is false but R is true

Attempted by 151 students.

Show answer & explanation

Correct answer: A

An XOR linked list enables a doubly linked structure using a single pointer per node by storing the bitwise XOR of previous and next addresses. Since both statements are true and Reason correctly explains Assertion, Option 0 is the correct choice.

A video solution is available for this question — log in and enroll to watch it.

Explore the full course: Coding For Placement