(A) v edges
(B) v – e + 5 edges
(C) v + e edges
(D) None of these
Tag: Fundamentals of Algorithms
What is generally true of Adjacency List and Adjacency Matrix representations of graphs?
(A) Lists require less space than matrices but take longer to find the weight of an edge (v1,v2)
(B) Lists require less space than matrices and they are faster to find the weight of an edge (v1,v2)
(C) Lists require more space than matrices and they take longer to find the weight of an edge (v1,v2)
(D) Lists require more space than matrices but are faster to find the weight of an edge (v1,v2)
If a problem is in NP, it must also be in P?
(A) True
(B) False
(C) NA
(D) NA
The number of nodes in a complete binary tree of height h is?
(A) 2^(h+1) – 1
(B) 2 * (h+1) – 1
(C) 2 * (h+1)
(D) ((h+1) ^ 2) – 1
Analysis of Selection Sort ends up with?
(A) T(n)
(B) T(1/1+n)
(C) T(n/2)
(D) T((n/2) +n)
Divide-and-Conquer is as breaking the problem into a small number of?
(A) Smaller Sub Problems
(B) Pivot
(C) Sieve
(D) Solutions
If there are O(n2) entries in edit distance matrix then the total running time is?
(A) O(1)
(B) O(n^2)
(C) O(n)
(D) O(n log n)
Is it possible to sort without making comparisons?
(A) True
(B) False
(C) NA
(D) NA