Reputation: 89
I know the concept of linearity in data structures. But I want to know that what Data Structures are Linear and what are Non-Linear. Please show me the list of both types of data structures that we use commonly.
Upvotes: 0
Views: 3031
Reputation: 1
In Linear Data Structures, data members are accessed sequentially.
Examples: Arrays, Linked Lists, Queues, Stacks, Double Linked Lists.
In Non-Linear Data Structures, a data member may have connections with several other data members; these structures follow no set sequence.
Examples: Graphs, Trees.
Upvotes: 0