Math Is Fun Forum

  Discussion about math, puzzles, games and fun.   Useful symbols: ÷ × ½ √ ∞ ≠ ≤ ≥ ≈ ⇒ ± ∈ Δ θ ∴ ∑ ∫ • π ƒ -¹ ² ³ °

You are not logged in.

#1 2010-01-18 15:31:14

yinyinchen2001
Member
Registered: 2010-01-18
Posts: 1

Help with Big-O notation

Hi everyone,

I'm having problems with Big-O notation, I'm somewhat understand how to solve the K and the C but I'm not quite sure how to solve this particular question

f(n) is O(g(n))
First question:
f(n) = n^2
when n is even then g(n) = n
when n is odd then g(n) = n^3

Second question:
f(n) = n^2 + 1000n
when n <= 100 then g(n) = n
when n > 100 then g(n) = n^3

The question is do I need to solve two k and two c or one k and one c will be okay for each question.
Do I need to look at the question as a whole or two separate entities. mad

Can someone kindly tell me how to solve these questions

Thank you in advance big_smile

Last edited by yinyinchen2001 (2010-01-18 15:31:30)

Offline

Board footer

Powered by FluxBB