example of linear and non-linear data structures?

Answer Posted / sneha rajput

A data structure is classified into two categories: Linear and Non-Linear data structures. A data structure is said to be linear if the elements form a sequence, for example Array, Linked list, queue etc. Elements in a nonlinear data structure do not form a sequence, for example Tree, Hash tree, Binary tree, etc.

There are two ways of representing linear data structures in memory. One way is to have the linear relationship between the elements by means of sequential memory locations. Such linear structures are called arrays. The other way is to have the linear relationship between the elements represented by means of links. Such linear data structures are called linked list.

Is This Answer Correct ?    4 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is dynamic data structure?

707


Define splay tree?

593


What actions are performed when a function is called?

563


List the area of applications of data structure.

764


What are lists?

523






Given an array of integers, devise a program to replace every element with the next greatest element on the right side in the array. Also, replace the last element with 5 as there no element on the right side of it.

563


Differentiate bfs and dfs?

561


What is the idea behind splaying?

1258


List the applications of set adt?

494


State the difference between queues and linked lists?

537


Define terminal nodes in a tree?

557


What is stable sort?

511


How do stacks work?

505


Describe linear probing with an example.

595


Is sorting a math skill?

487