More Classes
5th Class
6th Class
7th Class
8th Class
9th Class
10th Class
11th Class
12th Class
NAT I
NAT II
CSS
IQ
General Knowledge
MDCAT
ECAT
GAT General
GAT Subject
Other Links
Go to Home
Online Tests
CS-301 Final Term Exams Preparation Virtual University MCQs With Answers
Question # 1
The difference between the binary tree and a binary search tree is that:
Choose an answer
a binary search tree has two children per node whereas a binary tree can have none, one, or two children per node
in binary search tree nodes are inserted based on the values they contain
in binary tree nodes are inserted based on the values they contain
none of these
Previous
Skip
Next
Question # 2
If you know the size of the data structure in advance, i.e., at compile time, which one of the following is a good data structure to use.
Choose an answer
Array
List
Both
None of the above
Previous
Skip
Next
Question # 3
The definition of transitive property is
Choose an answer
For all element x member of S, x R x
For all elements x and y, x R y if and only if y R x
For all elements x, y and z, if x R y and y R z then x R z
For all elements w, x, y and z, if x R y and w R z then x R z
Previous
Skip
Next
Question # 4
Searching of an element in an AVL tree take minimum ____ time (where n is number of nodes in AVL tree)
Choose an answer
Log
2
(n+1)
Log
2
(n+1) -1
1.44 Log
2
n
1.66 Log
2
n
Previous
Skip
Next
Question # 5
By using __________we avoid the recursive method of traversing a Tree, which makes use of stacks and consumes a lot of memory and time.
Choose an answer
Binary tree only
Threaded binary tree
Heap data structure
Huffman encoding
Previous
Skip
Next
Question # 6
Which of the following is not an example of equivalence relation:
Choose an answer
Electrical Connectivity
Set of people
<= relation
Set of pixels
Previous
Skip
Next
Question # 7
If there are N elements in an array then the number of maximum steps needed to find an element using Binary Search is _______ .
Choose an answer
N
N
2
Nlog
2
N
log
2
N
Previous
Skip
Next
Question # 8
In an array list the current element is
Choose an answer
the first element
the middle element
the last element
The element where the current pointer points to
Previous
Skip
Next
Question # 9
A complete binary tree of height ____ has nodes between 16-31.
Choose an answer
2
3
4
5
Previous
Skip
Next
Question # 10
Use of binary tree in compression of data is known as _______
Choose an answer
Traversal
Heap
Union
Huffman encoding
Previous
Skip
Next
Question # 11
If there are 56 internal node in a binary tree then how many external nodes this binary tree will have ?
Choose an answer
54
55
56
57
Previous
Skip
Next
Back