f(x) is O(g(x)) and g(x) is O(h(x))
is f(x) O(h(x))?
Follow Math Help Forum on Facebook and Google+
I dont think so, but might wnat to wait until you get an second opinion to confirm this.
Yes, it is. Think of f(x) as a wrapper around a function with cost h(x) (you know the function costs h(x) because O(g(x)) = h(x). The big-O cost of a function is the sum of its cost and all the costs of its children.
View Tag Cloud