https://daniu.luogu.org/problemnew/show/3153 #include<queue> #include<cstdio> #include<cstring> #include<iostream> using namespace std; #define N 2501 #define M 3001 #define inf 2e9 int n,k; ]; ][]; int tot; ],nxt[M<<],val[M&
http://hzwer.com/1986.html #include<cstdio> #include<algorithm> #include<queue> #include<cstring> using namespace std; #define INF 2147483647 #define N 51 int n,m; char a[N][N]; queue<int>q; int S,T,nn; int first[(N<<2)