题目链接:hdu 4941 Magical Forest 题目大意:给定N,M和K,表示在一个N*M的棋盘上有K个棋子,给出K个棋子的位置和值,然后是Q次操作,对应的是: 1 a b :交换a和b两行2 a b : 交换a和b两列3 a b :查询a b这个位置上棋子的值,没有棋子的话输出0 解题思路:一开始X[i]
题目链接:hdu 5154 Harry and Magical Computer #include <cstdio>#include <cstring>#include <vector>#include <algorithm>using namespace std;const int maxn = 105;int N, M, s[maxn], v[maxn];vector<int>
题目: Magical Forest Time Limit: 24000/12000 MS (Java/Others) Memory Limit: 131072/131072 K (Java/Others) Total Submission(s): 389 Accepted Submission(s): 186 Problem Description The
There are NN cities in the country, and MM directional roads from uu to v(1\le u, v\le n)v(1≤u,v≤n). Every road has a distance c_ic i . Haze is a Magical Girl that lives in City 11, she can choose
1000ms 262144K There are N cities in the country, and M directional roads from u to v(1≤u,v≤n). Every road has a distance ci. Haze is a Magical Girl that lives in City 1, she can choose no more tha