1. When new data are to be inserted into a data structure, but there is not
available space; this situation is usually called ….
A.
Underflow
B.
overflow
C.
houseful
D.
saturated
Ans:
B. overflow
2 .
Which is/are the application(s) of stack
A)
Function calls
B)
Large number Arithmetic
C)
Evaluation of arithmetic expressions
D) All
of the above
Ans:
D) All of the above
3. which of the
following data structure is non linear type?
A) String
B)Lists
C) Stacks
D) Graph
Ans: D) Graph
4.which of the
following data structure is linear type?
A) Graph
B) Trees
C) Binary Tree
D) Stack
Ans: D) Stack
5. Which of the data
structure can't store the non-homogeneous data elements?
A) array
B) Records
C) Pointers
D) Stacks
Ans: A)
array
__________________________Points to remember______________________________
Types of Data structures:
There are two types of data structure
i) Linear (Stack,liked list,queue )
ii) Nonlinear (eg. Graph, Tree)
The more commonly used
data structures include lists,arrays,stacks ,queues,heaps, trees and graph.
Arrays:
The
simple type of data structure is linear array. A linear array is list of
a finite number of n of similar data elements .
Linked
list:
A list
is an ordered structure of data.It is often used to store objects that are to
be processed sequentially . A list can be used to create a queue.
Stack:
A stack is a last in, first out (LIFO)
data structure. Items are removed from a stack in the reverse order from
the way they were inserted
There are two stack
errors that can occur:
Underflow: trying
to pop an empty stack
Overflow: trying
to push onto an already full stack
Queue:
A queue is a first in, first out (FIFO)
data structure. This is accomplished by inserting at one end (the rear)
and deleting from the other (the front).Items are removed from a queue in the
same order as they were inserted.The process to add an element into queue is
called Enqueue and the process of removal of an element from queue is called
Dequeue.
Deque
A deque is a double-ended queue. Items
can be inserted and removed at either end. Deques (pronounced deck) are not heavily used. Deque" is not to be confused with dequeueing (
a queue operation)
Trees:
Data
frequently contain a hierarchical relationships between various elements . The
data structure which reflects this relationships is called a rooted tree graph
or a tree.
Graph :
Graphs
are data structures rather like trees. Graphs often have a shape dictated by a
physical or abstract problem . For example , nodes in a graph may
represent cities , while edges may represent airline flight routes between the
cities . Nodes are traditionally called vertices