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
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 # 2
Suppose you implement a heap (with the largest element on top) in an array. Consider the different arrays below, determine the one that cannot possibly be a heap:
Choose an answer
7 6 5 4 3 2 1
7 3 6 2 1 4 5
7 6 4 3 5 2 1
7 3 6 4 2 5 1
Previous
Skip
Next
Question # 3
Which of the following method is helpful in creating the heap at once?
Choose an answer
insert
add
update
preculateDown
Previous
Skip
Next
Question # 4
Compiler uses which one of the following to evaluate a mathematical equation
Choose an answer
Binary Tree
Binary Search Tree
Parse Tree
AVL Tree
Previous
Skip
Next
Question # 5
We are given N items to build a heap ,this can be done with ______ successive inserts.
Choose an answer
N-1
N
N+1
N+2
Previous
Skip
Next
Question # 6
In a selection sort of n element ,how many times the swap function is called the execution of the algorithm?
Choose an answer
n-1
0
n log n
1
Previous
Skip
Next
Question # 7
While building Huffman encoding tree the new node that is the result of joining two nodes has the frequency.
Choose an answer
Equal to the small frequency
Equal to the greater
Equal to the sum of the two frequencies
Equal to the difference of the two frequencies
Previous
Skip
Next
Question # 8
"+” is a _________operator.
Choose an answer
Unary
Binary
Ternary
None of the above
Previous
Skip
Next
Question # 9
Which one of the following is TRUE about recursion ?
Choose an answer
Recursion extensively use stack memory
Threaded Binary Trees use the concept of recursion.
Recursive function calls consume a lot of memory.
Iteration is more efficient than iteration.
Previous
Skip
Next
Question # 10
_________ is a data structure that can grow easily dynamically at run time without having to copy existing elements.
Choose an answer
Array ()
List
Both of these
None of these
Previous
Skip
Next
Question # 11
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
Back