Update time_complexity.md
This commit is contained in:
parent
f5a92cd682
commit
c02d84e387
@ -1,6 +1,6 @@
|
|||||||
# Time complexity
|
# Time complexity
|
||||||
Time complexity describes the run time of an algorithm as a function of the size of the input data.
|
|
||||||
The direct way to assess the efficiency of an algorithm is measuring the run time. How to accurately measure the run time of an algorithm?
|
The runtime can intuitively assess the efficiency of an algorithm. How can we accurately estimate the runtime of a piece of an algorithm?
|
||||||
|
|
||||||
1. **Determining the Running Platform**: This includes hardware configuration, programming language, system environment, etc., all of which can affect the efficiency of code execution.
|
1. **Determining the Running Platform**: This includes hardware configuration, programming language, system environment, etc., all of which can affect the efficiency of code execution.
|
||||||
2. **Evaluating the Run Time for Various Computational Operations**: For instance, an addition operation `+` might take 1 ns, a multiplication operation `*` might take 10 ns, a print operation `print()` might take 5 ns, etc.
|
2. **Evaluating the Run Time for Various Computational Operations**: For instance, an addition operation `+` might take 1 ns, a multiplication operation `*` might take 10 ns, a print operation `print()` might take 5 ns, etc.
|
||||||
|
Loading…
Reference in New Issue
Block a user