摘要:
这题就是从1到n点进行遍历,对未加热的点找到最远的能加热到这个点的点,还是看代码讲吧 #include"bits/stdc++.h" using namespace std; const int inf=0x3f3f3f3f; typedef long long LL; int a[1005],an 阅读全文
摘要:
迪杰斯特拉算法--O(n^2) #include"iostream" #include"cstring" #include"cstdio" using namespace std; const int inf = 0x3f3f3f3f; typedef long long LL; int map[1 阅读全文
摘要:
快速幂(本代码中的^表示次幂不是异或) Accepted 1061 0MS 1368K 679 B G++ #include "bits/stdc++.h" using namespace std; const int MOD = 10; int quick_pow(int n, int m) { 阅读全文