Question:

Which of the following is not a non linear data structure ?

Show Hint

Non-linear = Branching (Trees, Graphs). Linear = Straight line (Arrays, Lists).
Updated On: Aug 6, 2026
  • Binary tree
  • Heap
  • Graph
  • char
Show Solution
collegedunia
Verified By Collegedunia

The Correct Option is D

Solution and Explanation

Concept:
• Data structures are classified based on how data elements are organized.
Linear Data Structures: Elements are arranged in a sequence (e.g., Array, Stack, Queue, Linked List).
Non-Linear Data Structures: Elements are not arranged in a sequence; they form hierarchical or interconnected relationships (e.g., Trees, Graphs).

Step 1:
Identify the non-linear structures among the options

Binary Tree (Option A): A hierarchical structure where each node has at most two children. Clearly non-linear.
Heap (Option B): A specialized tree-based data structure (often represented in an array, but logically a complete binary tree). Non-linear.
Graph (Option C): A set of vertices connected by edges in a non-sequential web. Non-linear.

Step 2:
Analyze the "char" data type
A "char" (character) is a basic data type in programming. While it is not a "structure" in the same way a tree is, it represents a single scalar value. If we consider it in the context of data organization, characters are treated linearly (like in a string/array). More importantly, it definitely does not possess the hierarchical or networked properties required for a non-linear classification.

Step 3:
Final conclusion
Since the question asks for what is not non-linear, "char" is the only correct fit as it is a primitive/scalar type, and the others are explicitly non-linear structures.
Was this answer helpful?
0
0

Top CUET PG Data Science A.I Cyber Security and Computer Sci. Questions

View More Questions

Top CUET PG Programming and Data Structures Questions

View More Questions