Jump to content

about time complexity


gate13

Recommended Posts

Explain to me why anything takes longer than constant time to run.

 

Because sorting a longer list, for example, takes more time than a short list. How much longer depends on the sort algorithm.

A quick question:

If f(n) = log n, and g(n) = square root of n , which is the best description for the time complexity???

would it be

g(n) = O(f(n)) ?

 

Are you asking about the time complexity of log(n) and sqrt(n)? If so, I'm not sure it is possible to answer this without knowing how they are implemented. If not, I'm not sure what the question is ....

Link to comment
Share on other sites

never mind I solved it

 

!

Moderator Note

Please don't EVER delete your OP like that again. Thread closed, sorry to future readers who might have learned something, if they knew what the question was.

.
Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.