摘要:
https://www.luogu.com.cn/problem/P1803 调试出现了re while(cur>z[cnt].a&&cnt<n); 错写成了 while(cur>z[cnt].a); 导致了先越界了,外层的while还没有判断 #include<bits/stdc++.h> usi 阅读全文
摘要:
https://www.luogu.com.cn/problem/P1051 1.用cin输入字符串,省事 #include<bits/stdc++.h> using namespace std; struct stu{ int num; string name; int score; int py 阅读全文
摘要:
https://www.luogu.com.cn/problem/P1208 #include<bits/stdc++.h> using namespace std; struct farmer{ int price; int amount; }; struct farmer a[5050]; bo 阅读全文
摘要:
https://www.luogu.com.cn/problem/P1090 优先队列 小根堆 priority_queue<int,vector<int>,greater<int> >q; 大根堆 priority_queue <int > q; #include<bits/stdc++.h> u 阅读全文