带当前弧优化 gap优化的sap 甚至省去了开始的bfs分层 虽然花了一些时间了解原理 但是感觉不亏 现在能完全独立靠原理写出具体实现了 #include<cstdio> #include<cstring> using namespace std; , maxm = , inf = 0x3f3f3f3f; int st, ed, tot, n, m; struct Edge{ int u, v, nxt, w, f; Edge(){} Edge(int u, int v, int…
Pahom on Water Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others) Total Submission(s): 629 Accepted Submission(s): 288 Problem Description Pahom on Water is an interactive computer game inspired by a short story of…