Question 1

(a) Define data structure. List the various linear and non-linear data structures and explain them in brief.
 The possible ways in which the data items or atoms are logically related define data
Linear Data Structures: Array, Stack, Queue, Linked List.
Non-Linear Data Structures: Tree, Graph.
Following are the Linear Data Structures:
Array: An array is an ordered set which consists of a fixed number of objects. No
deletion or insertion operations are performed on arrays.
Stack: A collection of items in which only the most recently added item may be
removed. The latest added item is at the top. Basic operations are push and pop. Also
known as "last-in, first-out" or LIFO. Queue: A collection of items in which only the earliest added item may be accessed.
Basic operations are add (to the tail) or enqueue and delete (from the head) or dequeue.
Delete returns the item removed. Also known as "first-in, first-out" or FIFO. Linked List: A list implemented by each item having a link to the next item.
Following are the Non-Linear Data Structures:
Tree: A data structure accessed beginning at the root node. Each node is either a leaf or
an internal node. An internal node has one or more child nodes and is called the parent
of its child nodes. All children of the same node are siblings. Contrary to a physical tree,
the root is usually depicted at the top of the structure, and the leaves are depicted at the
Graph: A Graph: A set of items connected by edges. Each item is called a vertex or node.
Formally, a graph is a set of vertices and a binary relation between vertices, adjacency.
(b) Discuss the basic operations performed with linear structure.
 Following are the basic operations with linear structure:
1.) Traversing: It means passing through the every element one by one which stored in
the particular structure.
2.) Insertion: It means to insert an element in the particular structure.
3.) Deletion: It means to delete an element in the particular structure.
4.) Searching: It means to find desired element which is stored in the particular
5.) Sorting: It means to arrange the elements of the particular structure in
ascending/descending order.

Make Comments..!!

variya hemal
Nice and easy explain....!
Like · Comment ·
jay savaliya and rahul kumar like this
Harsh Patel
nice explain...
Like · Comment ·
Patel Chintan
can i get prmitive & non-primitive data structure?
Like · Comment ·
Download Android App