上一页 1 ··· 8 9 10 11 12 13 14 15 16 ··· 18 下一页
摘要: 点击查看代码 #include<bits/stdc++.h> using namespace std; typedef pair<int,int> PII; const int N=1e6+10,M=4e6+10; int h[N],idx,e[M],ne[M]; int n,m; int cnt[ 阅读全文
posted @ 2026-01-22 17:04 AnoSky 阅读(2) 评论(0) 推荐(0)
摘要: 点击查看代码 #include<bits/stdc++.h> using namespace std; typedef pair<int,int> PII; const int N=1005,M=100005; struct Graph{ int h[N],e[M],ne[M],idx,w[M]; 阅读全文
posted @ 2026-01-22 11:44 AnoSky 阅读(1) 评论(0) 推荐(0)
摘要: 点击查看代码 #include<bits/stdc++.h> using namespace std; typedef pair<int,int> PII; const int N=1005,M=100005; int h1[N],e1[M],idx1,ne1[M],w1[M]; int h2[N] 阅读全文
posted @ 2026-01-22 10:58 AnoSky 阅读(1) 评论(0) 推荐(0)
摘要: 点击查看代码 #include<bits/stdc++.h> using namespace std; const int MAXN = 205; const int INF = 1e9; // 定义一个足够大的数代表无穷大 int n, m; int t[MAXN]; //存每个村庄的修复时间 i 阅读全文
posted @ 2026-01-18 23:56 AnoSky 阅读(7) 评论(0) 推荐(0)
摘要: 点击查看代码 #include<bits/stdc++.h> using namespace std; typedef pair<int,int> PII; const int N=3000; const int M=7000*2; int n,m,s,t; struct Edge{ int to; 阅读全文
posted @ 2026-01-18 21:53 AnoSky 阅读(3) 评论(0) 推荐(0)
摘要: 点击查看代码 #include<bits/stdc++.h> using namespace std; const int N=110; const int M=10010; int n,m; int p[N]; int dist[N][N]; long long ans; int main() { 阅读全文
posted @ 2026-01-18 21:52 AnoSky 阅读(3) 评论(0) 推荐(0)
摘要: 点击查看代码 #include<bits/stdc++.h> using namespace std; typedef pair<int,int> PII; const int MAXN=1e5+10; const int MAXM=1e6+10; const int INF=2147483647; 阅读全文
posted @ 2026-01-18 17:34 AnoSky 阅读(4) 评论(0) 推荐(0)
摘要: 点击查看代码 #include<bits/stdc++.h> using namespace std; //起始点和终点 string start_str, end_str; string rule_from[10], rule_to[10]; // 对应的变换规则 int rule_count = 阅读全文
posted @ 2026-01-15 23:57 AnoSky 阅读(8) 评论(0) 推荐(0)
摘要: 点击查看代码 #include<bits/stdc++.h> using namespace std; string start_s; string goal="123804765"; int dx[4]={-1,0,0,1}; int dy[4]={0,-1,1,0}; void bfs() { 阅读全文
posted @ 2026-01-15 21:29 AnoSky 阅读(7) 评论(0) 推荐(0)
摘要: 点击查看代码 #include<bits/stdc++.h> using namespace std; typedef pair<int,int> PII; const int N=510; char g[N][N]; int dist[N][N]; int n,m; int dx[4]={-1,- 阅读全文
posted @ 2026-01-15 18:40 AnoSky 阅读(2) 评论(0) 推荐(0)
上一页 1 ··· 8 9 10 11 12 13 14 15 16 ··· 18 下一页