File tree Expand file tree Collapse file tree 1 file changed +8
-0
lines changed Expand file tree Collapse file tree 1 file changed +8
-0
lines changed Original file line number Diff line number Diff line change 7
7
- 评价算法的好坏:渐近时间复杂度和渐近空间复杂度。
8
8
9
9
- 渐近时间复杂度的大O标记:
10
+ - <img src =" http://latex.codecogs.com/gif.latex?O(c) " /> - 常量时间复杂度 - 布隆过滤器 / 哈希存储
11
+ - <img src =" http://latex.codecogs.com/gif.latex?O(log_2n) " /> - 对数时间复杂度 - 折半查找(二分查找)
12
+ - <img src =" http://latex.codecogs.com/gif.latex?O(n) " /> - 线性时间复杂度 - 顺序查找 / 桶排序
13
+ - <img src =" http://latex.codecogs.com/gif.latex?O(n*log_2n) " /> - 对数线性时间复杂度 - 高级排序算法(归并排序、快速排序)
14
+ - <img src =" http://latex.codecogs.com/gif.latex?O(n^2) " /> - 平方时间复杂度 - 简单排序算法(选择排序、插入排序、冒泡排序)
15
+ - <img src =" http://latex.codecogs.com/gif.latex?O(n^3) " /> - 立方时间复杂度 - Floyd算法 / 矩阵乘法运算
16
+ - <img src =" http://latex.codecogs.com/gif.latex?O(2^n) " /> - 几何级数时间复杂度 - 汉诺塔
17
+ - <img src =" http://latex.codecogs.com/gif.latex?O(n!) " /> - 阶乘时间复杂度 - 旅行经销商问题 - NP
10
18
- $O(c)$ - 常量时间复杂度 - 布隆过滤器 / 哈希存储
11
19
- $O(log_2n)$ - 对数时间复杂度 - 折半查找(二分查找)
12
20
- $O(n)$ - 线性时间复杂度 - 顺序查找 / 桶排序
You can’t perform that action at this time.
0 commit comments