Order Notation
Hello, could you guys tell me if i did this correctly based on the question since I am confused whether best run time means it grows the slowest or not?
Q) Rank the functions in Table 2 from best to worst runtime. Specifically, you should rank f (n) before g(n) if, and only if, f (n) = o(g(n)). There may be some ties (functions that grow at the same rate); you should indicates this with ”=”.![]()
Best to Worst
(j) = (h)
(a)
(k) = (i) = (f) = (c)
(e) = (d)
(L)
(b)
Q) Rank in increasing order of growth rate
The second line is my solution![]()
Answer
- The questioner was satisfied with and accepted the answer, or
- The answer was evaluated as being 100% correct by the judge.
-
There is two parts one question at the bottom too! and Is this in best to worst run time? meaning (j) and (h) are the best run time and (a) is the worst run time? Also I am a bit confused about the constant, doesn't a constant have a slower run time than suppose a log function and therefore has a better run time
-
Yes, it is best to worst run time (smallest run time to the largest run time). About the constant function, note that log (n) goes to infinity as n gets large which is much larges than a constant. So a constant run time is better than any log (n).
-
-
I will add my solution to the second part in a few minutes.
-
Thank you, I appreciate your help!
-
You're most welcome :)
-
-
Oh okay I understand now! Thank you. I think you may have missed the other part that is below
-
Oh sorry, I will wait
-
- answered
- 736 views
- $15.00
Related Questions
- Solve summation problem: $\sum_{k=1}^{n} \tfrac{2k+1}{k^{2}(k+1)^2 } $
- Count the number of decks of cards, where no king is on top of the ace of the same suit.
- Discrete math
- Probability of making a full house in a poker hand
- Logic Question π΄∨π΅→πΆβ’(π΄→πΆ)∧(π΅→πΆ)
- Combinatorial Counting: Painting Streetlight Poles with Color Restrictions
- Discete Math
- Logic Question π΄→(π΅→πΆ),π΄→π΅,π΄β’πΆ