- 博客(10)
- 收藏
- 关注
原创 PAT 1121 Damn Single
#include <iostream> #include <vector> #include <map> #include <set> using namespace std; map<string,string> st1; set<string> ans; set<string> tt; int main() ...
2020-03-31 15:45:37
135
原创 PAT1106DFS为什么会有段错误呢
#include <iostream> #include <vector> #include <cmath> #include <algorithm> using namespace std; int cnt = 0; int minth = 99999; struct NODE{ int id; vector<int>...
2020-03-29 00:20:53
236
原创 PAT1102用笨办法解翻转二叉树
#include <iostream> #include <string> #include <vector> #include <algorithm> #include <queue> using namespace std; struct node{ int id,l,r; }a[100]; int root = 0; bo...
2020-03-28 19:17:17
141
原创 PAT1092字符比较类
#include <iostream> #include <string> using namespace std; int main() { string a,b; cin >> a; cin >> b; int lena = a.length(); int tempa = lena; int le...
2020-03-27 19:54:36
359
原创 PAT 1047 用set的自动排序有一组超时,还得用二维数组和然后比较字典序自己排序
#include <iostream> #include <set> #include <string> using namespace std; int main() { int n,m; cin >>n>>m; set<string> s[m]; for(int i=0;i<n;i...
2020-03-23 15:20:28
157
原创 PAT1039为什么有一组超时数据呢
#include <iostream> #include <vector> #include <algorithm> #include <map> #include <set> using namespace std; map<string,set<int>> tt; vector<string> s...
2020-03-22 15:51:06
224
原创 PAT甲级1036 记录关于sort函数报错问题,太粗心了
如果是结构体类型的STL容器,用sort排序必须带上cmp函数不然报错。。 #include <iostream> #include <algorithm> #include <vector> #include <cmath> using namespace std; typedef struct Node{ string ...
2020-03-21 22:14:25
252
原创 PAT 1029
这个好像比柳婼大神的简单些 #include <iostream> #include <algorithm> #include <cstring> using namespace std; int a1[2000005]; int main() { int n,m; cin >> n; for(int i = 0;i<...
2020-03-21 12:53:44
111
原创 1082 射击比赛 (20分)
简单一遍对 #include <vector> #include <algorithm> #include <iostream> #include <map> using namespace std; int main() { int n; cin >> n; getchar(); int name[100...
2020-03-08 22:58:47
112
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人
RSS订阅