#timecomplexity — Public Fediverse posts
Live and recent posts from across the Fediverse tagged #timecomplexity, aggregated by home.social.
-
@benbenbrubaker @rrwilliams @tomgur @boazbaraktcs @joshuagrochow @ccanonne @manlius
Ooops!
Yet wouldn't doubt that also will appear on that list:#AlgorithmicComplexity
#ComputationalComplexity
#TimeComplexity -
@benbenbrubaker @rrwilliams @tomgur @boazbaraktcs @joshuagrochow @ccanonne @manlius
Ooops!
Yet wouldn't doubt that also will appear on that list:#AlgorithmicComplexity
#ComputationalComplexity
#TimeComplexity -
Time Complexity (Big O) simplified:
- When your calculation is not dependent on the input size, it is a constant time complexity (O(1)).
- When the input size is reduced by half, maybe when iterating, handling recursion, or whatsoever, it is a logarithmic time complexity (O(log n)).
- When you have a single loop within your algorithm, it is linear time complexity (O(n)).
- When you have nested loops within your algorithm, meaning a loop in a loop, it is quadratic time complexity (O(n^2)).
- When the growth rate doubles with each addition to the input, it is exponential time complexity (O2^n).