

MCQOPTIONS
Saved Bookmarks
This section includes 397 Mcqs, each offering curated multiple-choice questions to sharpen your Computer Science Engineering (CSE) knowledge and support exam preparation. Choose a topic below to get started.
351. |
Recursive selection sort is a comparison based sort. |
A. | true |
B. | false |
Answer» B. false | |
352. |
What will be the best case time complexity of recursive selection sort? |
A. | o(n) |
B. | o(n2) |
C. | o(log n) |
D. | o(n log n) |
Answer» C. o(log n) | |
353. |
Which of the following sorting algorithm is NOT stable? |
A. | selection sort |
B. | brick sort |
C. | bubble sort |
D. | merge sort |
Answer» B. brick sort | |
354. |
Which of the following is the biggest advantage of selection sort? |
A. | its has low time complexity |
B. | it has low space complexity |
C. | it is easy to implement |
D. | it requires only n swaps under any condition |
Answer» E. | |
355. |
What will be the recurrence relation of the code of recursive selection sort? |
A. | t(n) = 2t(n/2) + n |
B. | t(n) = 2t(n/2) + c |
C. | t(n) = t(n-1) + n |
D. | t(n) = t(n-1) + c |
Answer» D. t(n) = t(n-1) + c | |
356. |
Which of the following sorting algorithm has best case time complexity of O(n2)? |
A. | bubble sort |
B. | selection sort |
C. | insertion sort |
D. | stupid sort |
Answer» C. insertion sort | |
357. |
What will be the time complexity of the code to reverse stack recursively? |
A. | o(n) |
B. | o(n log n) |
C. | o(log n) |
D. | o(n2) |
Answer» E. | |
358. |
What is the time complexity of the program to reverse stack when linked list is used for its implementation? |
A. | o(n) |
B. | o(n log n) |
C. | o(n2) |
D. | o(log n) |
Answer» B. o(n log n) | |
359. |
Which of the following statement is true about stack? |
A. | pop operation removes the top most element |
B. | pop operation removes the bottom most element |
C. | push operation adds new element at the bottom |
D. | push operation removes the top most element |
Answer» B. pop operation removes the bottom most element | |
360. |
How many recursive calls are there in Recursive matrix multiplication by Strassen’s Method? |
A. | 5 |
B. | 7 |
C. | 8 |
D. | 4 |
Answer» C. 8 | |
361. |
What is the time complexity of matrix multiplied recursively by Divide and Conquer Method? |
A. | o(n) |
B. | o(n2) |
C. | o(n3) |
D. | o(n!) |
Answer» D. o(n!) | |
362. |
What is the time complexity of the above recursive implementation used to reverse a string? |
A. | o(1) |
B. | o(n) |
C. | o(n2) |
D. | o(n3) |
Answer» C. o(n2) | |
363. |
Which of the following methods can be used to find the sum of digits of a number? |
A. | recursion |
B. | iteration |
C. | greedy algorithm |
D. | both recursion and iteration |
Answer» E. | |
364. |
Which algorithm is the most efficient numerical algorithm to obtain lcm? |
A. | euler’s algorithm |
B. | euclid’s algorithm |
C. | chebyshev function |
D. | partial division algorithm |
Answer» C. chebyshev function | |
365. |
Is lcm an associative function. |
A. | true |
B. | false |
Answer» B. false | |
366. |
What is the following expression, lcm (a, gcd (a, b)) equal to? |
A. | a |
B. | b |
C. | a*b |
D. | a + b |
Answer» B. b | |
367. |
What is the following expression, lcm (a, lcm (b, c) equal to? |
A. | lcm (a, b, c) |
B. | a*b*c |
C. | a + b + c |
D. | lcm (lcm (a, b), c) |
Answer» E. | |
368. |
Is 9 and 28 coprime number. |
A. | true |
B. | false |
Answer» B. false | |
369. |
What is the lcm (a, b)? |
A. | a + b |
B. | gcd (a-b, b) if a>b |
C. | lcm (b, a) |
D. | a – b |
Answer» D. a – b | |
370. |
What is the LCM according to the given Venn Diagram? |
A. | 2 |
B. | 3 c) 180 |
C. | d) 6 |
Answer» D. | |
371. |
In terms of Venn Diagram, which of the following expression gives LCM (Given A ꓵ B ≠Ø)? |
A. | multiplication of a u b terms |
B. | multiplication of a ꓵ b terms |
C. | multiplication of a*b terms |
D. | multiplication of a-b terms |
Answer» B. multiplication of a ꓵ b terms | |
372. |
What is the LCM of two coprime numbers? |
A. | 1 |
B. | 0 |
C. | addition of two coprime numbers |
D. | multiplication of two coprime numbers |
Answer» E. | |
373. |
Which of the following is also known as LCM? |
A. | lowest common divisor |
B. | least common multiple |
C. | lowest common measure |
D. | highest common multiple |
Answer» B. least common multiple | |
374. |
Which is the smallest number of 3 digits that is divisible by 2, 4, 8? |
A. | 100 |
B. | 102 |
C. | 116 |
D. | 104 |
Answer» E. | |
375. |
LCM is also called as |
A. | gcd |
B. | scm |
C. | gcf |
D. | hcf |
Answer» C. gcf | |
376. |
What is the computational complexity of Binary GCD algorithm where a and b are integers? |
A. | o (log a + log b)2) |
B. | o (log (a + b)) |
C. | o (log ab) |
D. | o (log a-b) |
Answer» B. o (log (a + b)) | |
377. |
Who gave the expression for the probability and expected value of gcd? |
A. | james e. nymann |
B. | riemann |
C. | thomae |
D. | euler |
Answer» B. riemann | |
378. |
Is gcd an associative function. |
A. | true |
B. | false |
Answer» B. false | |
379. |
If gcd (a, b) is defined by the expression, d=a*p + b*q where d, p, q are positive integers and a, b is both not zero, then what is the expression called? |
A. | bezout’s identity |
B. | multiplicative identity |
C. | sum of product |
D. | product of sum |
Answer» B. multiplicative identity | |
380. |
Is 9 and 28 coprime number? |
A. | true |
B. | false |
Answer» B. false | |
381. |
What is the GCD of 48, 18, 0? |
A. | 24 |
B. | 2 |
C. | 3 |
D. | 6 |
Answer» E. | |
382. |
What is the GCD of a and b? |
A. | a + b |
B. | gcd (a-b, b) if a>b |
C. | gcd (a+b, a-b) |
D. | a – b |
Answer» C. gcd (a+b, a-b) | |
383. |
What is the GCD according to the given Venn Diagram? |
A. | 2 |
B. | 3 |
C. | 5 |
D. | 6 |
Answer» D. 6 | |
384. |
In terms of Venn Diagram, which of the following expression gives GCD (Given A ꓵ B ≠Ø)? |
A. | multiplication of a u b terms |
B. | multiplication of a ꓵ b terms |
C. | multiplication of a*b terms |
D. | multiplication of a-b terms |
Answer» C. multiplication of a*b terms | |
385. |
Which of the following is also known as GCD? |
A. | highest common divisor |
B. | highest common multiple |
C. | highest common measure |
D. | lowest common multiple |
Answer» B. highest common multiple | |
386. |
If GCD of two number is 8 and LCM is 144, then what is the second number if first number is 72? |
A. | 24 |
B. | 2 |
C. | 3 |
D. | 16 |
Answer» E. | |
387. |
Which of the following is coprime number? |
A. | 54 and 24 |
B. | 4 and 8 |
C. | 6 and 12 |
D. | 9 and 28 |
Answer» E. | |
388. |
Which of the following gives the sum of the first n natural numbers? |
A. | nc2 |
B. | (n-1)c2 |
C. | (n+1)c2 |
D. | (n+2)c2 |
Answer» D. (n+2)c2 | |
389. |
Which of the following recurrence relations can be used to find the nth fibonacci number? |
A. | f(n) = f(n) + f(n – 1) |
B. | f(n) = f(n) + f(n + 1) |
C. | f(n) = f(n – 1) |
D. | f(n) = f(n – 1) + f(n – 2) |
Answer» E. | |
390. |
Which of the following option is wrong? |
A. | fibonacci number can be calculated by using dynamic programming |
B. | fibonacci number can be calculated by using recursion method |
C. | fibonacci number can be calculated by using iteration method |
D. | no method is defined to calculate fibonacci number |
Answer» E. | |
391. |
Which of the following is not a fibonnaci number? |
A. | 8 |
B. | 21 |
C. | 55 |
D. | 14 |
Answer» E. | |
392. |
Suppose the first fibonnaci number is 0 and the second is 1. What is the sixth fibonnaci number? |
A. | 5 |
B. | 6 |
C. | 7 |
D. | 8 |
Answer» B. 6 | |
393. |
Which of the following recursive formula can be used to find the factorial of a number? |
A. | fact(n) = n * fact(n) |
B. | fact(n) = n * fact(n+1) |
C. | fact(n) = n * fact(n-1) |
D. | fact(n) = n * fact(1) |
Answer» D. fact(n) = n * fact(1) | |
394. |
In general, which of the following methods isn’t used to find the factorial of a number? |
A. | recursion |
B. | iteration |
Answer» B. iteration | |
395. |
Which of the following problems can’t be solved using recursion? |
A. | factorial of a number |
B. | nth fibonacci number |
C. | length of a string |
D. | problems without base case |
Answer» E. | |
396. |
Recursion is a method in which the solution of a problem depends on |
A. | larger instances of different problems |
B. | larger instances of the same problem |
C. | smaller instances of the same problem |
D. | smaller instances of different problems |
Answer» D. smaller instances of different problems | |
397. |
Recursion is similar to which of the following? |
A. | switch case |
B. | loop |
C. | if-else |
D. | if elif else |
Answer» C. if-else | |