Skip to content
Related Articles
Get the best out of our app
GFG App
Open App
geeksforgeeks
Browser
Continue

Related Articles

Algorithms | Analysis of Algorithms | Question 15

Improve Article
Save Article
Like Article
Improve Article
Save Article
Like Article

Consider the following functions

  • f(n) = 3n^{\sqrt{n}}
  • g(n) = 2^{\sqrt{n}{\log_{2}n}}
  • h(n) = n!

Which of the following is true? (GATE CS 2000)
(A) h(n) is 0(f(n))
(B) h(n) is 0(g(n))
(C) g(n) is not 0(f(n))
(D) f(n) is 0(g(n))

(A)

A

(B)

B

(C)

C

(D)

D


Answer: (D)

Explanation:

g(n) = 2^(\\sqrt{n} \\log{n} ) = n^(\\sqrt{n}) f(n) and g(n) are of same asymptotic order and following statements are true. f(n) = O(g(n)) g(n) = O(f(n)). (a) and (b) are false because n! is of asymptotically higher order than n^(\\sqrt{n}) .


Quiz of this Question
Please comment below if you find anything wrong in the above post

My Personal Notes arrow_drop_up
Last Updated : 28 Jun, 2021
Like Article
Save Article
Similar Reads