摘要:
使用一维数组优化 复杂度 \(n^{2}\) 总体复杂度 \(500^{2} = 2.5 \times 10^{5}\) 点击查看代码 #include<iostream> using namespace std; const int N = 510, INF = 1e9; int n; int a 阅读全文
posted @ 2022-05-20 18:28
wKingYu
阅读(22)
评论(0)
推荐(0)
摘要:
点击查看代码 #include<iostream> using namespace std; const int N = 110; int n, m; int v[N][N], w[N][N], s[N]; int f[N]; int main() { cin >> n >> m; for (int 阅读全文
posted @ 2022-05-20 17:28
wKingYu
阅读(24)
评论(0)
推荐(0)
摘要:
\(n, v, s\) 都较小 朴素写法 时间复杂度 \(n \times v \times s\) 总体复杂度 \(100^{3} = 1 \times 10^{6}\) 点击查看代码 #include<iostream> using namespace std; const int N = 11 阅读全文
posted @ 2022-05-20 16:48
wKingYu
阅读(34)
评论(0)
推荐(0)

浙公网安备 33010602011771号