SlideShare a Scribd company logo
(01) Which of the following properties are necessary for an Algorithm?
(A) Definite ness (B) correct ness (C) Effectiveness (D) A and C
(02) which of the following technique is not using for solve a 0-1knapsack problem
(A) Greedy (B) Dynamic programming (C) branch and bound (D) all of the above
(03)For the following program gives Big O analysis of the running time (in terms of n)
For (i=0; i<n; i++)
A[i] = +;
(A)O(n-1) (B) O(n) (C) O(n2
) (D) O(log n)
(04) For the following program gives Big O analysis of the running time (in terms of n)
For (i=0; i< n; i++)
For (j=i; j< n; j++)
For (k=j; k< n; k++)
S++;
(A)O(n-1) (B) O(n2
) (C) O(n3
) (D) O(log n)
(05) For the following program gives Big O analysis of the running time (in terms of n)
For (i=0; i < n*n; i++)
A[i] = i;
(A)O(n-1) (B) O(n2
) (C) O(n3
) (D) O(log n)
(06) Given f(n) = log2
n
, g(n) = √n which function is asymptotically faster
(A) f(n) is faster than g(n) (B) g(n) is faster than f(n)
(C) Either f(n) or g(n) (D) Neither f(n) nor g(n)
(07) Which of the following are true
(a) 33n3
+ 4n2
= p (n2
) (b) n! = O(nn
) (c) 10n2
+ 9 = O(n2
) (d) 6n3
/(log n +1) = O(n3
) (A) a,b and c
(B)a and c (C) a and b (D) all are true
(08) n! =
(A) O( 2n
) (B) ω(2n
) (C) A and B (D) O(n100
)
None of them are correct
(09) T (n) = 8T (n/2) + n2
, T (1) = 1 then T (n) =
(A) ϴ(n2
) (B) ϴ(n3
) (C) ϴ(n4
)
(10) T (n) = 3T (n/4) + n then T (n) =
(D) ϴ(n)
(A) O (n2
) (B) O (n3
) (C) O (n)
(11) T (n) = 4T (n/2) + n then T (n) =
(D) O (n4
)
(A) ϴ(n2
) (B) ϴ(n3
) (C) ϴ(n4
)
(12) T (n) = 2T (n/2) + cn then T (n) =
(D) ϴ(n)
(A) O (log n) (B) O (n log n) (C) O (n2
log n) (D) O (n2
)
(13) T (n) = 2T (n/2) + n2
then T (n) =
(A) ϴ(n2
) (B) ϴ(n3
) (C) ϴ(n4
)
(14) T (n) = 2T (n/2) + n2
then T (n) =
(D) ϴ(n)
(A) O (n3
) (B) O (n2
) (C) O (n)
(15) T (n) = 9T (n/3) + n then T (n) =
(D) O (n4
)
(A) ϴ(n4
) (B) ϴ(n3
) (C) ϴ(n2
)
(16) T (n) = T (n/2) + 1 then T (n) =
(D) ϴ(n)
(A) O (log n) (B) O (2 log n) (C) O (n log n) (D) O (n2
)
(17) T (n) = T (n/2) + n2
then T (n) =
(A) ϴ(n4
) (B) ϴ(n3
) (C) ϴ(n2
) (D) ϴ(n)
(18) T (n) = 4T (n/2) + n2
then T (n) =
(A) ϴ(n log n) (B) ϴ(n3
log n) (C) ϴ(n2
log n) (D) ϴ(n4
log n)
(19) T (n) = 7T (n/2) + n2
then T (n) =
(A) ϴ(n2.5
) (B) ϴ(n2.807
) (C) ϴ(n2.85
)
(20) T (n) = 2T (n/2) + n3
then T (n) =
(D) ϴ(n2.75
)
(A) ϴ(n4
) (B) ϴ(n3
) (C) ϴ(n2
)
(21) T (n) = T (9n/10) + n then T (n) =
(D) ϴ(n)
(A) ϴ(n4
) (B) ϴ(n3
) (C) ϴ(n2
)
(22) T (n) = 16T (n/4) + n2
then T (n) =
(D) ϴ(n)
(A) ϴ(n log n) (B) ϴ(n3
log n) (C) ϴ(n2
log n) (D) ϴ(n4
log n)
(23) T (n) = 7T (n/3) + n2
then T (n) =
(A) ϴ(n4
) (B) ϴ(n3
) (C) ϴ(n2
)
(24) T (n) = 7T (n/2) + n2
then T (n) =
(D) ϴ(n)
(A) ϴ(nlog7
) (B) ϴ(nlog5
) (C) ϴ(nlog9
)
(25) T (n) = 2T (n/2) + n3
then T (n) =
(D) ϴ(nlog3
)
(A) ϴ(n4
) (B) ϴ(n3
) (C) ϴ(n2
)
(26 T (n) = 2T (n/4) + √n then T (n) ) =
(D) ϴ(n)
(A) ϴ(n log n) B) ϴ(√n log n( )(C) ϴ(n2
log n) (D) ϴ(n3
log n)
(27 T (n) = T (√n) +1 then T (n) = )
(A) ϴ(n log n) B) ϴ(√n log n( ) (C) ϴ(log n) (D) ϴ(n2
log n)
(28) T (n) = 100T (n/99) + log (n!) then T (n) =
(A) ϴ(n log n)B) ϴ(√n log n( ) (C) ϴ(n2
log n) (D) ϴ(n3
log n)
(29) T (n) = T (n-1) + n4
then T (n) =
(A) ϴ(n4
) (B) ϴ(n3
) (C) ϴ(n2
) (D) ϴ(n)
(30) T (n) = 2T (n/2) + 3n2
and T (1) = 11 then T (n) =
(A) O (n3
) (B) O (n2
) (C) O (n) (D) O (n4
)
(31) T (n) = 1 for n=1
= 2 * T (n - 1) for n >1 then T (n) =
(A)2 n (B) 2 n-1 (C) 2 n-2(D) 2 n-3
(32) T (n) = 4T (n/2) + n2
√n then T (n) =
(A) ϴ(n3
√n) (B) ϴ(n2
) (C) ϴ(n2
√n) D) ϴ(n√n( )
(33) T (n) = 2T (n/2) + (n/ log n) then T (n) =
(A) ϴ(n log n) (B) ϴ(n log n log n)
(C) ϴ(n2
log n log n) (D) ϴ(n2
log n)
(34) T (n) = T (n/2) + T (n/4) + T (n/8) + n then T (n) =
(A) ϴ(n4
) (B) ϴ(n3
) (C) ϴ(n2
) (D) ϴ(n)
(35) Set defines as
(A) Distinct objects (B) Similar elements (C) collection of elements (D) objects
(36) A machine took 200 sec to sort 200 names, using bubble sort. In 800 sec, it can
approximately sort
(A) 400 names (B) 800 names (C) 750 names (D) 1800 names
(37) Linked lists are not suitable for
(A) Insertion sort (B) Binary search (C) Radix sort (D) Polynomial manipulation
(38) Which of the following is useful in implementing quick sort?
(A) Stack (B) List (B) Set (D) Queue
(39) A machine needs a minimum of 100 sec to sort 1000 names by quick sort. The minimum
time needed to sort 1000 names by quick sort. The minimum time needed to sort 100 names
will be approximately?
(A) 50.2 sec (B) 6.7 sec (C) 72.7 sec (D) 11.2 sec
(40) Given 2 sorted lists of size ‘m’ and ‘n’ respectively. Number of comparisons needed in the
worst case by the merge sort algorithm will be
(A) mn (B) max(m,n) (C) min(m,n) (D) m+n-1
(41) The depth of a complete binary tree with ‘n’ nodes is
(A) log (n+1)-1 (B) log n (C) log (n-1)+ 1 (D) log n +1
(42) Average successful search time taken by binary search on a sorted array of items is
(A) 2.6 (B) 2.7 (C) 2.8 (D) 2.9
(43) Average successful search time for sequential search on ‘n’ items is
(A) n/2 (B) (n-1)/2 (C) (n+1)/2 (D) n2
(44) The maximum number of comparisons needed to sort 7 items using radix sort is (assume
each item is a 4 digit decimal number)
(A) 280 (B) 40 (C) 47 (D) 38
(45) In Randomized Quick sort, the expected running time of any input is
(A) O(n) (B) O(n2
) (C) O(n log n ) (D) O(n3
)
(46) If Total complexity after micro analysis is 5n3
+ 10n2
+ 100 n +400 logn+ 10,
The Big Oh complexity is
(A)O(n2
) (B) O(n3
) (C) O(nlogn) (D) O(n2
logn)
(47) In Strassen’s Multiplication Algorithm the T(n) is
A) 7T (n) + bn2
B) 7T (n/2) + bn2
C) 8T (n/2) + bn2
D) 7T (n/2) + bn
(48) T (n) = 4 T (n/2) + n then in Big Oh Notation it is
A) O (n2
) B) O(4) (C) O(n) D) O(log(n))
(49) In T(n) = a * T(n/b) + f(n) , a refers to
(A) Size of sub problem (B) No. of sub problems
(C) Size of the problem (D) Time to combine solutions
(50) 0-1 knapsack be solved using
(A)dynamic programming (B) Backtracking (C) Branch & Bound
(D) All A,B,C,E (E) Genetic Programming
(51) In depth first search algorithm the no. of recursive calls we have to make are
(A) 2 (B) 1 (C) 6 (D) depends on the graph
(52) O (f(n)) minus O(f(n)) is equal to
(A) Zero (B) A constant (C) f(n) (D) O(f(n))
(53) Quick sort is solved using
(A) Divide and conquer (B) Greedy Programming
(C) Dynamic Programming (D) Branch and bound
(54) For i = 1 to n-1 do
2.1 For j = 1 to n-1-i do
2.2.1 If (a[j+1] < a[j]) then swap a[j] and a[j+1]
Given code is for
(A) Bubble sort (B) Insertion sort (C) Quick Sort (D) Selection Sort
(55) Worst case complexity of quick sort is
(A) O(n) (B) O(logn) (C) O(nlogn ) (D) O(n2
)
(56) The sub problems in Divide and Conquer are considered to be
A) Distinct (B) overlapping (C) large size (D) small size
(57) Which of the following name does not relate to stacks?
(A) FIFO lists (B) LIFO list (C) Piles (D) Push-down lists
(58 Which of the following data structure is linear type?
(A) Strings (B) Lists (C) Queues D) All of above
(59) In a graph if e=(u, v) means
(A) u is adjacent to v but v is not adjacent to u (B) e begins at u and ends at v
(C) u is processor and v is successor (D) both b and c
(60) An algorithm that calls itself directly or indirectly is known as
(A) Sub algorithm (B) Recursion (C) Polish notation (D) Traversal algorithm
(61) In a Heap tree
(A) Values in a node is greater than every value in left sub tree and smaller than right sub tree
(B) Values in a node is greater than every value in children of it
(C) Both of above conditions applies (D) none of above conditions applies (62)
Ada

More Related Content

What's hot

Application of parallel hierarchical matrices and low-rank tensors in spatial...
Application of parallel hierarchical matrices and low-rank tensors in spatial...Application of parallel hierarchical matrices and low-rank tensors in spatial...
Application of parallel hierarchical matrices and low-rank tensors in spatial...
Alexander Litvinenko
 
5.2 divede and conquer 03
5.2 divede and conquer 035.2 divede and conquer 03
5.2 divede and conquer 03
Krish_ver2
 
2020 preTEST3A
2020 preTEST3A2020 preTEST3A
2020 preTEST3A
A Jorge Garcia
 
Euclid algorithm and congruence matrix
Euclid algorithm and congruence matrixEuclid algorithm and congruence matrix
Euclid algorithm and congruence matrix
Janani S
 
preTEST3A Double Integrals Solved
preTEST3A Double Integrals SolvedpreTEST3A Double Integrals Solved
preTEST3A Double Integrals Solved
A Jorge Garcia
 
Daa divide-n-conquer
Daa divide-n-conquerDaa divide-n-conquer
Daa divide-n-conquer
sankara_rao
 
07- 22 Jan - Divide and Conquer
07- 22 Jan - Divide and Conquer07- 22 Jan - Divide and Conquer
07- 22 Jan - Divide and Conquer
Neeldhara Misra
 
preTEST1A Solved Multivariable Calculus
preTEST1A Solved Multivariable CalculuspreTEST1A Solved Multivariable Calculus
preTEST1A Solved Multivariable Calculus
A Jorge Garcia
 
Modular arithmetic
Modular arithmeticModular arithmetic
Modular arithmetic
Janani S
 
Logarithm - Simple
Logarithm - SimpleLogarithm - Simple
Logarithm - Simple
2IIM
 
ECES302 Exam 1 Solutions
ECES302 Exam 1 SolutionsECES302 Exam 1 Solutions
ECES302 Exam 1 Solutions
Thomas Woo
 
Directed Acyclic Graph
Directed Acyclic Graph Directed Acyclic Graph
Directed Acyclic Graph
AJAL A J
 
Logartihm - Algebra
Logartihm - AlgebraLogartihm - Algebra
Logartihm - Algebra
2IIM
 
Datastructure tree
Datastructure treeDatastructure tree
Datastructure tree
rantd
 
Number theoretic-rsa-chailos-new
Number theoretic-rsa-chailos-newNumber theoretic-rsa-chailos-new
Number theoretic-rsa-chailos-new
Christos Loizos
 
LAP2009 c&p101-vector2 d.5ht
LAP2009 c&p101-vector2 d.5htLAP2009 c&p101-vector2 d.5ht
LAP2009 c&p101-vector2 d.5ht
A Jorge Garcia
 
Logarithms intro
Logarithms introLogarithms intro
Logarithms intro
Shaun Wilson
 

What's hot (19)

Application of parallel hierarchical matrices and low-rank tensors in spatial...
Application of parallel hierarchical matrices and low-rank tensors in spatial...Application of parallel hierarchical matrices and low-rank tensors in spatial...
Application of parallel hierarchical matrices and low-rank tensors in spatial...
 
5.2 divede and conquer 03
5.2 divede and conquer 035.2 divede and conquer 03
5.2 divede and conquer 03
 
Review exercises
 Review exercises Review exercises
Review exercises
 
2020 preTEST3A
2020 preTEST3A2020 preTEST3A
2020 preTEST3A
 
Euclid algorithm and congruence matrix
Euclid algorithm and congruence matrixEuclid algorithm and congruence matrix
Euclid algorithm and congruence matrix
 
preTEST3A Double Integrals Solved
preTEST3A Double Integrals SolvedpreTEST3A Double Integrals Solved
preTEST3A Double Integrals Solved
 
Daa divide-n-conquer
Daa divide-n-conquerDaa divide-n-conquer
Daa divide-n-conquer
 
07- 22 Jan - Divide and Conquer
07- 22 Jan - Divide and Conquer07- 22 Jan - Divide and Conquer
07- 22 Jan - Divide and Conquer
 
preTEST1A Solved Multivariable Calculus
preTEST1A Solved Multivariable CalculuspreTEST1A Solved Multivariable Calculus
preTEST1A Solved Multivariable Calculus
 
Modular arithmetic
Modular arithmeticModular arithmetic
Modular arithmetic
 
Logarithm - Simple
Logarithm - SimpleLogarithm - Simple
Logarithm - Simple
 
ECES302 Exam 1 Solutions
ECES302 Exam 1 SolutionsECES302 Exam 1 Solutions
ECES302 Exam 1 Solutions
 
Directed Acyclic Graph
Directed Acyclic Graph Directed Acyclic Graph
Directed Acyclic Graph
 
Logartihm - Algebra
Logartihm - AlgebraLogartihm - Algebra
Logartihm - Algebra
 
Datastructure tree
Datastructure treeDatastructure tree
Datastructure tree
 
Number theoretic-rsa-chailos-new
Number theoretic-rsa-chailos-newNumber theoretic-rsa-chailos-new
Number theoretic-rsa-chailos-new
 
LAP2009 c&p101-vector2 d.5ht
LAP2009 c&p101-vector2 d.5htLAP2009 c&p101-vector2 d.5ht
LAP2009 c&p101-vector2 d.5ht
 
Alex1 group2
Alex1 group2Alex1 group2
Alex1 group2
 
Logarithms intro
Logarithms introLogarithms intro
Logarithms intro
 

Similar to Ada

Add math may june 2016 p1
Add math may june 2016 p1Add math may june 2016 p1
Add math may june 2016 p1
Don Cunningham
 
cl 9 polynomial.pdf
cl 9 polynomial.pdfcl 9 polynomial.pdf
cl 9 polynomial.pdf
TanishqAgarwal27
 
Paper computer
Paper computerPaper computer
Paper computerbikram ...
 
Paper computer
Paper computerPaper computer
Paper computerbikram ...
 
Kanodia murolia previousyears
Kanodia murolia previousyearsKanodia murolia previousyears
Kanodia murolia previousyearsAnwesa Roy
 
Banco de preguntas para el ap
Banco de preguntas para el apBanco de preguntas para el ap
Banco de preguntas para el ap
MARCELOCHAVEZ23
 
AP PGECET Computer Science 2016 question paper
AP PGECET Computer Science 2016 question paperAP PGECET Computer Science 2016 question paper
AP PGECET Computer Science 2016 question paper
Eneutron
 
mathematics question bank for engineering students
mathematics question bank for engineering studentsmathematics question bank for engineering students
mathematics question bank for engineering students
MrMRubanVelsUniversi
 
12th mcq
12th mcq12th mcq
12th mcq
nitishguptamaps
 
12th mcq
12th mcq12th mcq
12th mcq
nitishguptamaps
 
Ee693 sept2014midsem
Ee693 sept2014midsemEe693 sept2014midsem
Ee693 sept2014midsem
Gopi Saiteja
 
ObjectiveQuestionsonEngineeringMathematicsForGATE2022.pdf
ObjectiveQuestionsonEngineeringMathematicsForGATE2022.pdfObjectiveQuestionsonEngineeringMathematicsForGATE2022.pdf
ObjectiveQuestionsonEngineeringMathematicsForGATE2022.pdf
MohammedArish6
 
Maieee03
Maieee03Maieee03
Maieee03
Ashish Yadav
 
Aieee 2003 maths solved paper by fiitjee
Aieee 2003 maths solved paper by fiitjeeAieee 2003 maths solved paper by fiitjee
Aieee 2003 maths solved paper by fiitjeeMr_KevinShah
 
9th class maths MCQs by Ustani G.docx
9th class maths MCQs by Ustani G.docx9th class maths MCQs by Ustani G.docx
9th class maths MCQs by Ustani G.docx
Waseem798409
 
02 definite Intergration Ex. Module-5.pdf
02 definite Intergration  Ex. Module-5.pdf02 definite Intergration  Ex. Module-5.pdf
02 definite Intergration Ex. Module-5.pdf
RajuSingh806014
 
Maths mind paper 2013
Maths mind paper 2013Maths mind paper 2013
Maths mind paper 2013
nitishguptamaps
 
Gate-Cs 2006
Gate-Cs 2006Gate-Cs 2006
Gate-Cs 2006
Ravi Rajput
 

Similar to Ada (19)

Add math may june 2016 p1
Add math may june 2016 p1Add math may june 2016 p1
Add math may june 2016 p1
 
cl 9 polynomial.pdf
cl 9 polynomial.pdfcl 9 polynomial.pdf
cl 9 polynomial.pdf
 
1
11
1
 
Paper computer
Paper computerPaper computer
Paper computer
 
Paper computer
Paper computerPaper computer
Paper computer
 
Kanodia murolia previousyears
Kanodia murolia previousyearsKanodia murolia previousyears
Kanodia murolia previousyears
 
Banco de preguntas para el ap
Banco de preguntas para el apBanco de preguntas para el ap
Banco de preguntas para el ap
 
AP PGECET Computer Science 2016 question paper
AP PGECET Computer Science 2016 question paperAP PGECET Computer Science 2016 question paper
AP PGECET Computer Science 2016 question paper
 
mathematics question bank for engineering students
mathematics question bank for engineering studentsmathematics question bank for engineering students
mathematics question bank for engineering students
 
12th mcq
12th mcq12th mcq
12th mcq
 
12th mcq
12th mcq12th mcq
12th mcq
 
Ee693 sept2014midsem
Ee693 sept2014midsemEe693 sept2014midsem
Ee693 sept2014midsem
 
ObjectiveQuestionsonEngineeringMathematicsForGATE2022.pdf
ObjectiveQuestionsonEngineeringMathematicsForGATE2022.pdfObjectiveQuestionsonEngineeringMathematicsForGATE2022.pdf
ObjectiveQuestionsonEngineeringMathematicsForGATE2022.pdf
 
Maieee03
Maieee03Maieee03
Maieee03
 
Aieee 2003 maths solved paper by fiitjee
Aieee 2003 maths solved paper by fiitjeeAieee 2003 maths solved paper by fiitjee
Aieee 2003 maths solved paper by fiitjee
 
9th class maths MCQs by Ustani G.docx
9th class maths MCQs by Ustani G.docx9th class maths MCQs by Ustani G.docx
9th class maths MCQs by Ustani G.docx
 
02 definite Intergration Ex. Module-5.pdf
02 definite Intergration  Ex. Module-5.pdf02 definite Intergration  Ex. Module-5.pdf
02 definite Intergration Ex. Module-5.pdf
 
Maths mind paper 2013
Maths mind paper 2013Maths mind paper 2013
Maths mind paper 2013
 
Gate-Cs 2006
Gate-Cs 2006Gate-Cs 2006
Gate-Cs 2006
 

Ada

  • 1. (01) Which of the following properties are necessary for an Algorithm? (A) Definite ness (B) correct ness (C) Effectiveness (D) A and C (02) which of the following technique is not using for solve a 0-1knapsack problem (A) Greedy (B) Dynamic programming (C) branch and bound (D) all of the above (03)For the following program gives Big O analysis of the running time (in terms of n) For (i=0; i<n; i++) A[i] = +; (A)O(n-1) (B) O(n) (C) O(n2 ) (D) O(log n) (04) For the following program gives Big O analysis of the running time (in terms of n) For (i=0; i< n; i++) For (j=i; j< n; j++) For (k=j; k< n; k++) S++; (A)O(n-1) (B) O(n2 ) (C) O(n3 ) (D) O(log n) (05) For the following program gives Big O analysis of the running time (in terms of n) For (i=0; i < n*n; i++) A[i] = i;
  • 2. (A)O(n-1) (B) O(n2 ) (C) O(n3 ) (D) O(log n) (06) Given f(n) = log2 n , g(n) = √n which function is asymptotically faster (A) f(n) is faster than g(n) (B) g(n) is faster than f(n) (C) Either f(n) or g(n) (D) Neither f(n) nor g(n) (07) Which of the following are true (a) 33n3 + 4n2 = p (n2 ) (b) n! = O(nn ) (c) 10n2 + 9 = O(n2 ) (d) 6n3 /(log n +1) = O(n3 ) (A) a,b and c (B)a and c (C) a and b (D) all are true (08) n! = (A) O( 2n ) (B) ω(2n ) (C) A and B (D) O(n100 ) None of them are correct (09) T (n) = 8T (n/2) + n2 , T (1) = 1 then T (n) = (A) ϴ(n2 ) (B) ϴ(n3 ) (C) ϴ(n4 ) (10) T (n) = 3T (n/4) + n then T (n) = (D) ϴ(n) (A) O (n2 ) (B) O (n3 ) (C) O (n) (11) T (n) = 4T (n/2) + n then T (n) = (D) O (n4 ) (A) ϴ(n2 ) (B) ϴ(n3 ) (C) ϴ(n4 ) (12) T (n) = 2T (n/2) + cn then T (n) = (D) ϴ(n) (A) O (log n) (B) O (n log n) (C) O (n2 log n) (D) O (n2 ) (13) T (n) = 2T (n/2) + n2 then T (n) = (A) ϴ(n2 ) (B) ϴ(n3 ) (C) ϴ(n4 ) (14) T (n) = 2T (n/2) + n2 then T (n) = (D) ϴ(n)
  • 3. (A) O (n3 ) (B) O (n2 ) (C) O (n) (15) T (n) = 9T (n/3) + n then T (n) = (D) O (n4 ) (A) ϴ(n4 ) (B) ϴ(n3 ) (C) ϴ(n2 ) (16) T (n) = T (n/2) + 1 then T (n) = (D) ϴ(n) (A) O (log n) (B) O (2 log n) (C) O (n log n) (D) O (n2 ) (17) T (n) = T (n/2) + n2 then T (n) = (A) ϴ(n4 ) (B) ϴ(n3 ) (C) ϴ(n2 ) (D) ϴ(n) (18) T (n) = 4T (n/2) + n2 then T (n) = (A) ϴ(n log n) (B) ϴ(n3 log n) (C) ϴ(n2 log n) (D) ϴ(n4 log n) (19) T (n) = 7T (n/2) + n2 then T (n) = (A) ϴ(n2.5 ) (B) ϴ(n2.807 ) (C) ϴ(n2.85 ) (20) T (n) = 2T (n/2) + n3 then T (n) = (D) ϴ(n2.75 ) (A) ϴ(n4 ) (B) ϴ(n3 ) (C) ϴ(n2 ) (21) T (n) = T (9n/10) + n then T (n) = (D) ϴ(n) (A) ϴ(n4 ) (B) ϴ(n3 ) (C) ϴ(n2 ) (22) T (n) = 16T (n/4) + n2 then T (n) = (D) ϴ(n) (A) ϴ(n log n) (B) ϴ(n3 log n) (C) ϴ(n2 log n) (D) ϴ(n4 log n) (23) T (n) = 7T (n/3) + n2 then T (n) = (A) ϴ(n4 ) (B) ϴ(n3 ) (C) ϴ(n2 ) (24) T (n) = 7T (n/2) + n2 then T (n) = (D) ϴ(n) (A) ϴ(nlog7 ) (B) ϴ(nlog5 ) (C) ϴ(nlog9 ) (25) T (n) = 2T (n/2) + n3 then T (n) = (D) ϴ(nlog3 )
  • 4. (A) ϴ(n4 ) (B) ϴ(n3 ) (C) ϴ(n2 ) (26 T (n) = 2T (n/4) + √n then T (n) ) = (D) ϴ(n) (A) ϴ(n log n) B) ϴ(√n log n( )(C) ϴ(n2 log n) (D) ϴ(n3 log n) (27 T (n) = T (√n) +1 then T (n) = ) (A) ϴ(n log n) B) ϴ(√n log n( ) (C) ϴ(log n) (D) ϴ(n2 log n) (28) T (n) = 100T (n/99) + log (n!) then T (n) = (A) ϴ(n log n)B) ϴ(√n log n( ) (C) ϴ(n2 log n) (D) ϴ(n3 log n) (29) T (n) = T (n-1) + n4 then T (n) = (A) ϴ(n4 ) (B) ϴ(n3 ) (C) ϴ(n2 ) (D) ϴ(n) (30) T (n) = 2T (n/2) + 3n2 and T (1) = 11 then T (n) = (A) O (n3 ) (B) O (n2 ) (C) O (n) (D) O (n4 ) (31) T (n) = 1 for n=1 = 2 * T (n - 1) for n >1 then T (n) = (A)2 n (B) 2 n-1 (C) 2 n-2(D) 2 n-3 (32) T (n) = 4T (n/2) + n2 √n then T (n) = (A) ϴ(n3 √n) (B) ϴ(n2 ) (C) ϴ(n2 √n) D) ϴ(n√n( ) (33) T (n) = 2T (n/2) + (n/ log n) then T (n) = (A) ϴ(n log n) (B) ϴ(n log n log n) (C) ϴ(n2 log n log n) (D) ϴ(n2 log n) (34) T (n) = T (n/2) + T (n/4) + T (n/8) + n then T (n) = (A) ϴ(n4 ) (B) ϴ(n3 ) (C) ϴ(n2 ) (D) ϴ(n) (35) Set defines as
  • 5. (A) Distinct objects (B) Similar elements (C) collection of elements (D) objects (36) A machine took 200 sec to sort 200 names, using bubble sort. In 800 sec, it can approximately sort (A) 400 names (B) 800 names (C) 750 names (D) 1800 names (37) Linked lists are not suitable for (A) Insertion sort (B) Binary search (C) Radix sort (D) Polynomial manipulation (38) Which of the following is useful in implementing quick sort? (A) Stack (B) List (B) Set (D) Queue (39) A machine needs a minimum of 100 sec to sort 1000 names by quick sort. The minimum time needed to sort 1000 names by quick sort. The minimum time needed to sort 100 names will be approximately? (A) 50.2 sec (B) 6.7 sec (C) 72.7 sec (D) 11.2 sec (40) Given 2 sorted lists of size ‘m’ and ‘n’ respectively. Number of comparisons needed in the worst case by the merge sort algorithm will be (A) mn (B) max(m,n) (C) min(m,n) (D) m+n-1 (41) The depth of a complete binary tree with ‘n’ nodes is (A) log (n+1)-1 (B) log n (C) log (n-1)+ 1 (D) log n +1 (42) Average successful search time taken by binary search on a sorted array of items is (A) 2.6 (B) 2.7 (C) 2.8 (D) 2.9 (43) Average successful search time for sequential search on ‘n’ items is (A) n/2 (B) (n-1)/2 (C) (n+1)/2 (D) n2 (44) The maximum number of comparisons needed to sort 7 items using radix sort is (assume each item is a 4 digit decimal number) (A) 280 (B) 40 (C) 47 (D) 38
  • 6. (45) In Randomized Quick sort, the expected running time of any input is (A) O(n) (B) O(n2 ) (C) O(n log n ) (D) O(n3 ) (46) If Total complexity after micro analysis is 5n3 + 10n2 + 100 n +400 logn+ 10, The Big Oh complexity is (A)O(n2 ) (B) O(n3 ) (C) O(nlogn) (D) O(n2 logn) (47) In Strassen’s Multiplication Algorithm the T(n) is A) 7T (n) + bn2 B) 7T (n/2) + bn2 C) 8T (n/2) + bn2 D) 7T (n/2) + bn (48) T (n) = 4 T (n/2) + n then in Big Oh Notation it is A) O (n2 ) B) O(4) (C) O(n) D) O(log(n)) (49) In T(n) = a * T(n/b) + f(n) , a refers to (A) Size of sub problem (B) No. of sub problems (C) Size of the problem (D) Time to combine solutions (50) 0-1 knapsack be solved using (A)dynamic programming (B) Backtracking (C) Branch & Bound (D) All A,B,C,E (E) Genetic Programming (51) In depth first search algorithm the no. of recursive calls we have to make are (A) 2 (B) 1 (C) 6 (D) depends on the graph (52) O (f(n)) minus O(f(n)) is equal to (A) Zero (B) A constant (C) f(n) (D) O(f(n)) (53) Quick sort is solved using (A) Divide and conquer (B) Greedy Programming (C) Dynamic Programming (D) Branch and bound (54) For i = 1 to n-1 do
  • 7. 2.1 For j = 1 to n-1-i do 2.2.1 If (a[j+1] < a[j]) then swap a[j] and a[j+1] Given code is for (A) Bubble sort (B) Insertion sort (C) Quick Sort (D) Selection Sort (55) Worst case complexity of quick sort is (A) O(n) (B) O(logn) (C) O(nlogn ) (D) O(n2 ) (56) The sub problems in Divide and Conquer are considered to be A) Distinct (B) overlapping (C) large size (D) small size (57) Which of the following name does not relate to stacks? (A) FIFO lists (B) LIFO list (C) Piles (D) Push-down lists (58 Which of the following data structure is linear type? (A) Strings (B) Lists (C) Queues D) All of above (59) In a graph if e=(u, v) means (A) u is adjacent to v but v is not adjacent to u (B) e begins at u and ends at v (C) u is processor and v is successor (D) both b and c (60) An algorithm that calls itself directly or indirectly is known as (A) Sub algorithm (B) Recursion (C) Polish notation (D) Traversal algorithm (61) In a Heap tree (A) Values in a node is greater than every value in left sub tree and smaller than right sub tree (B) Values in a node is greater than every value in children of it (C) Both of above conditions applies (D) none of above conditions applies (62)