UGC NET STUDY MATERIALS

DATA STRUCTURE USING C

Sikkim Manipal University
Model Question Paper
Subject: Data Structure Using C
Subject code: BC 0038
Total Time: 2 hours
Total Marks: 140
Notes:
1. Question paper is divided into three parts i.e. Part A, Part B, and Part C.
2. Part A consist 40 questions of one mark each
3. Part B consist 20 questions of 2 marks each.
4. Part C consist 15 questions of 4 marks each.
5. All questions are compulsory
Part A (One Mark Question)
1)
int a[]={5,4,3,2,1} What is the value of a[3]?
a.
2
b.
3
c.
4
d.
1
2)
float a[10]; What is the size of the array?
a.
10
b.
20
c.
30
d.
40
3)
Array is :
a.
Primary data type
b.
Ho mogeneous data type
c.
Pointer data type
d.
Heterogeneous data type
4)
Array index can be started from 1?
a.
Yes
b.
No
5)
To accept 100 different values into the array we require:
a.
Loop
b.
If condition
c.
Function
d.
Structure
6)
Pointer holds
a.
Value o f variable
b.
Address of variable
c.
Value and address of variable
d.
Always null
1 |
P a g e



7)
A pointer can hold
a.
Two addresses at a time
b.
Single address at a time
c.
Number of addresses at a time
d.
No address
8)
main() {
int a=3,b=2,c,*d,*e;
d=&a; e=&b;
c=*d+*e;
}
Which one of the given answers is correct?
a.
a=4,c=6
b.
a=3, c=8
c.
a=3 , c=6
d.
a=3,c = 5
Assume that variable
x
resides at memor y location 100,
y
at 200 and
ip
at 1000.
9)
int x=1; y=2,*ip;
ip=&x;
y=*ip;
What will be the value of
y
after execution of above code?
a.
1
b.
2
c.
100
d.
1000
10)
Which of the following is the correct way of declaring an array of integer pointers?
a.
int *arr[10];
b.
int arr[10];
c.
*int arr[10];
d.
int *arr;
11)
If an integer occupies 4 bytes and a character occupies 1 byte of memory, each element of the
following structure would occupy how many bytes?
struct name {
int age;
char name[30];
};
2 |
P a g e



a.
32
b.
34
c.
30
d.
2
12)
A structure brings together a group of
a.
items of the same data type
b.
related data items and variables
c.
integers with user defined names
d.
floating points with user defined names
13)
To identify a member element of a structure we use :
a.
dot (.) operator
b.
plus(+) operator
c.
* operator
d.
& operator
14)
When the structure is accessed through pointer th en we use to access member elements by
a.
Dot (.) operator
b.
* operator
c.
operator
d.
& operator
15)
We can create array of structure:
a.
Yes
b.
No
16)
The data structure has the following components
a.
Algorithm, storage structure and function of implementation
b.
Algorithm, data type and function of implementation
c.
Function, storage structure and program
d.
Algorithm, data structure and program
17)
In linked list, the successive element
a.
Must occupy contiguous locations in memory
b.
Need not occupy contiguous space in memory
c.
Must not occupy contiguous locations in any situation
d.
None of the above
18)
Link pointer variable in linked list contain address of the
a.
Following node in the list
b.
Current node in the list
c.
First node in the list
d.
None of the above
19)
Which of the following liner list structure allow both insertion and deletion at only one end?
a.
Queue
3 |
P a g e



b.
Stack
c.
Circular queue
d.
d) None of the above
20)
Pick out invalid statement from following : Queues can be used for
a.
The line printer
b.
Access to disk storage
c.
Function call
d.
Main Memory Access
21)
In Stack we insert data from:
a.
Front End
b.
Rear End
c.
Both End
d.
Top End
22)
The Stack overflow occurs when
a.
When stack contains maximum elements
b.
When stack contains minimum elements
c.
When stack contains half of the maximum elements
d.
When stack is empty
23)
Stack maintains the algorithm
a.
LIFO
b.
FIFO
c.
FILO
d.
LILO
24)
The stack is easy to maintain by
a.
Array
b.
Link List
c.
Structure
d.
Union
25)
Application of Stack is :
a.
Function Call
b.
Storage data in memory
c.
Dynamic memory allocation
d.
Structure definition
26)
When PUSH operation is done then
a.
TOP=TOP+1
b.
TOP = TOP-1
c.
TOP=-1
d.
TOP=0
27)
When POP operation is done then
4 |
P a g e



a.
TOP=TOP+1
b.
TOP = TOP-1
c.
TOP=-1
d.
TOP=0
28)
We can change the insertion position of the Stack
a.
Yes
b.
No
29)
In the Sack STACK_SIZE is :
a.
Fixed
b.
Variable
30)
A stack cannot be used to
a.
evaluate an arithmetic expression in postfix form
b.
implement recursion
c.
convert infix form to postfix from of an expression
d.
allocate resources by operating system
31)
If the in-order pre-order traversal of a binary tree are D,B,F,E,G,H,A,C and A,B,D,E,F,G,H,C
respectively then post order will be:
a.
D,F,G,A,B,C,H,E
b.
F,H,D,G,E,B,C,A
c.
D,F,H,G,E,B,C,A
d.
C,G,H,F,E,D,B,A
32)
Stack is useful for implementing breadth first search
a.
True
b.
False
33)
The Polish Notation is
a.
Post order
b.
Pre order
c.
In order
d.
None of these
34)
Infix to post fix conversion we need :
a.
Stack
b.
Queue
c.
Structure
d.
Union
35)
Requirement of Polish Notation
a.
Because the notation does not have any priority
b.
Because the notation have priority
36)
What algorithm is used in Queue?
5 |
P a g e



a.
FILO
b.
LILO
c.
FIFO
d.
LIFO
37)
From which end of Queue elements are deleted?
a.
Rear
b.
Front
c.
Middle Position
d.
Any position of the queue
38)
The Queue Size can be
a.
Dynamically changed
b.
Static, cannot he changed
39)
POP from queue needs checking
a.
Queue Full Condition
b.
Queue Empty Condition
c.
Stack Full Condition
d.
Stack Empty Condition
40)
Queue is easy to implement by
a.
Array
b.
Link List
c.
Structure
d.
Union
Part B (Two Mark Question)
41)
Which of the following data structure may give overflow error, even though the current
number of elements in it is less than its size?
a.
Stack
b.
circular queue
c.
simple queue
d.
none of the abov e
42)
The basic problem of space utilization has been removed by
a.
Stack
b.
Circular Queue
c.
Double Ended Queue
d.
Queue Size
43)
What is the difference between Stack & Queue?
a.
Storage Structure
b.
Memory Allocation
c.
Algorithm
6 |
P a g e



d.
All of the Above
44)
Queue can be represented by
a.
Array
b.
Link List
c.
Tree
d.
Only a) and b) is correct
45)
Queue is
a.
Linear Data Structure
b.
Non Linear Data Structure
46)
Josephus Problem is the application of
a.
Ordinary Queue
b.
Circular Queue
c.
Double Ended Queue
d.
Priority Queue
47)
The priority queue requires FRONT and REAR:
a.
One only
b.
Multiple
c.
None
d.
Two only
48)
The access of Queue elements is
a.
Sequential
b.
Random
c.
Direct
d.
Indexed
49)
Front and Rear can be interchangeable in
a.
Dqueue
b.
Priority Queue
c.
Circular Queue
d.
Ordinary Queue
50)
One Application of Priority Queue is
a.
CPU scheduling
b.
Ready Queue for printing
c.
Data Access from RAM
d.
Reading data through Scanner
51)
Linked List is
a.
Linear Data Structure
b.
Non Linear Data Structure
52)
To create linked list created by
7 |
P a g e



a.
Structure
b.
Union
c.
Array
d.
Macro
53)
Each node of linked list has two parts
a.
Data & Address
b.
Data & Null
c.
Address & Null
d.
Address & Address
54)
Linked List allocate memory space in
a.
Direct fashion
b.
Contiguous fashion
c.
Random fashion
d.
Indexed fashion
55)
Advantage of Linked List over array
a.
Linked List occupies less memory
b.
Linked List can be stored in disk
c.
Deletion of nodes is easy than array
d.
Linked List is easy to maintain
56)
In Circular Link List
a.
Head node contains the address of tail node
b.
Tail node contains the address of the head
c.
Head node contains the address of the middle node
d.
Tail node contains the address of the middle node
57)
In Doubly Linked List each node contains
a.
No address part
b.
One address part
c.
Two address part
d.
Three address part
58)
We can traverse in either d irection
a.
Singular Linked List
b.
Circular Linked List
c.
Doubly Linked List
d.
Tree Linked List
59)
The application of Linked List
a.
Add two characters
b.
Add two large numbers
c.
Add two Strings
d.
Add two very small numbers
60)
Can we delete the head node from Doubly Linked List
8 |
P a g e



a.
True
b.
False
Part C (Four Mark Question)
61)
Which of the following statements is TRUE? A B-Tree of order
a.
24 contains at least 12 key in each non root node
b.
25 contains at least 12 keys in each node
c.
24 contains at least 23 keys in each non root node.
d.
None of the above.
62)
What is the minimum number of keys contained in each non root node of a B-Tree of order
11?
a.
4
b.
5
c.
3
d.
1
63)
If the degree of a node if 0 then the tree is called
a.
Trinary Tree
b.
Single Edged tree
c.
Single node tree
d.
Single degree tree
64)
Number of all possible binary trees with 2 nodes is
a.
1
b.
2
c.
3
d.
4
65)
Binary Tree Traversal is faster in
a.
Ordinary Binary Tree
b.
Binary Search Tree
c.
Threaded Binary Tree
d.
AVL Tree
66)
In co mplete binary tree the numb er of nodes in level 0 is
a.
0
b.
1
c.
2
d.
3
67)
AVL tree is a special types o f
a.
Binary Tree
b.
Binary Search Tree
c.
Threaded Binary Tree
d.
B-Tree
9 |
P a g e



68)
In AVL Tree, the Balance Factor is calculated as
a.
Left Height – Left Height
b.
Right Height – Right Height
c.
Left Height – Right Height
d.
Middle Height – Right Height
69)
The minimum balance factor of a node in AVL tree is
a.
-2
b.
-1
c.
0
d.
1
70)
The Polish Notation is
a.
Prefix notation
b.
Postfix notation
c.
Infix notation
d.
All of the above
71)
An adjacency matrix representation of a graph cannot contain information of
a.
Nodes
b.
Edges
c.
direction of edges
d.
parallel edge s
72)
The strongly connected graph
a.
can connect from one node to any other node
b.
can connect from few nodes to other few nodes
c.
cannot connect to other nodes
d.
can connect only one node
73)
If no parallel edges in a 4 vertices graph , what is the maximum degree of a vertex?
a.
4
b.
3
c.
2
d.
1
74)
For Graph Traversal
a.
DFS & BFS
b.
Prefix
c.
Infix
d.
Postfix
75)
Spanning Tree related to
a.
Kruskal’s lgorithm
b.
Piterson’s lgorithm
c.
Newton’s lgorithm
d.
Ratherford’s lgorithm
10 |
P a g e

Popular Posts

Recent Posts