Algorithm Analysis questions

Q3

GATE CS 2021 CS-1Algorithm AnalysisMCQ1 mark−1/3 if wrong
Consider the following three functions.
f1=10nf2=nlog⁡nf3=nnf_1 = 10^n \qquad f_2 = n^{\log n} \qquad f_3 = n^{\sqrt{n}}
Which one of the following options arranges the functions in the increasing order of asymptotic growth rate?
Show answer without attempting

Answer: D

Q30

GATE CS 2021 CS-1Algorithm AnalysisMCQ2 marks−2/3 if wrong
Consider the following recurrence relation.
T(n)={T(n/2)+T(2n/5)+7nif n>01if n=0T(n) = \begin{cases} T(n/2) + T(2n/5) + 7n & \text{if } n > 0 \\ 1 & \text{if } n = 0 \end{cases}
Which one of the following options is correct?
Show answer without attempting

Answer: C

Q8

GATE CS 2021 CS-2Algorithm AnalysisMCQ1 mark−1/3 if wrong
What is the worst-case number of arithmetic operations performed by recursive binary search on a sorted array of size nn?
Show answer without attempting

Answer: B

Q39

GATE CS 2021 CS-2Algorithm AnalysisMCQ2 marks−2/3 if wrong
For constants a≥1a \ge 1 and b>1b > 1, consider the following recurrence defined on the non-negative integers:

T(n)=a⋅T(nb)+f(n)T(n) = a \cdot T\left(\frac{n}{b}\right) + f(n)

Which of the following options is correct about the recurrence T(n)T(n)?
Show answer without attempting

Answer: C

0/40 correct0 marks

Related topics in Algorithms