摘要:
尺选法、反转。//176k, 485ms#include #include using namespace std;const int MAX = 20;const int dx[5] = {-1, 0, 0, 0, 1};const int dy[5] = {0, -1, 0, ... 阅读全文
摘要:
尺选法、反转。//212k, 344ms#include #include using namespace std;const int MAX_N = 5005;int n;int dir[MAX_N], f[MAX_N];int calc(int K) { memset(f... 阅读全文