上一页 1 2 3 4 5 6 ··· 8 下一页
摘要: #include <iostream>using namespace std;const int N=10010;int n,k;int a[N],q[N];int main(){ cin>>n>>k; for(int i=0;i<n;i++) cin>>a[i]; int hh=0,tt=-1; 阅读全文
posted @ 2022-03-26 09:57 小白QIU 阅读(34) 评论(1) 推荐(0)
摘要: #include <iostream>using namespace std;const int N=10010;int stk[N],tt;int main(){ int n; cin>>n; for(int i=0;i<n;i++) { int x; cin>>x; while(tt&&stk[ 阅读全文
posted @ 2022-03-24 13:04 小白QIU 阅读(61) 评论(0) 推荐(0)
摘要: #include <iostream>using namespace std;const int N=10010;int m;int e[N],l[N],r[N],idx;void init(){ //0表示左端点,1表示右端点 r[0]=1,l[1]=0; idx=2; }//在下标是k的点 的右 阅读全文
posted @ 2022-03-24 11:40 小白QIU 阅读(21) 评论(0) 推荐(0)
摘要: #include <iostream>using namespace std;const int N=10010;int a[N],s[N];int n;int main(){ cin>>n; int res=0; for(int i=0;i<n;i++) cin>>a[i]; for(int j= 阅读全文
posted @ 2022-03-21 21:12 小白QIU 阅读(60) 评论(1) 推荐(0)
摘要: #include <iostream>#include <algorithm>using namespace std;const int N=10010,INF=1e9;int n;int a[N][N],f[N][N];int main(){ cin>>n; for(int i=1;i<=n;i+ 阅读全文
posted @ 2022-03-20 09:11 小白QIU 阅读(74) 评论(1) 推荐(0)
摘要: #include <iostream>#include <algorithm>using namespace std;const int N=10010,INF=1e9;int a[N][N],f[N][N];int main(){ int x; cin>>x; while(x--) { int n 阅读全文
posted @ 2022-03-19 21:48 小白QIU 阅读(106) 评论(0) 推荐(0)
摘要: #include <iostream>#include <algorithm>using namespace std;const int N=50010;pair<int,int> cow[N];int n;int main(){ cin>>n;; for(int i=0;i<n;i++) { in 阅读全文
posted @ 2022-03-18 00:10 小白QIU 阅读(39) 评论(1) 推荐(0)
摘要: #include <iostream>#include <algorithm>using namespace std;const int N=10010;typedef long long LL;int a[N];int n;int main(){ cin>>n; LL res=0; for(int 阅读全文
posted @ 2022-03-17 23:11 小白QIU 阅读(25) 评论(1) 推荐(0)
摘要: #include <iostream>#include <algorithm>using namespace std;const int N=10010;int t[N];int n;int main(){ cin>>n; for(int i=0;i<n;i++) cin>>t[i]; sort(t 阅读全文
posted @ 2022-03-17 22:24 小白QIU 阅读(10) 评论(1) 推荐(0)
摘要: #include <iostream>#include <algorithm>#include <queue>using namespace std;int main(){ int n; cin>>n; priority_queue<int,vector<int>,greater<int> > he 阅读全文
posted @ 2022-03-17 18:27 小白QIU 阅读(40) 评论(1) 推荐(0)
上一页 1 2 3 4 5 6 ··· 8 下一页