Jump to content

about time complexity

Featured Replies

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

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 ....

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.

.

Archived

This topic is now archived and is closed to further replies.

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.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.