摘要:
#include #include #include #include #define N 1000010 using namespace std; int n,a[N],cnt1,cnt2; int read() { int x=0,f=1;char c=getchar(); while(c>'9'||c='0'&&c #include #include #in... 阅读全文
摘要:
/* (4,1)*(3,1)*(2,1)的话1变成2然后一直是2 2变成1然后变成3 3变成1然后变成4 4变成1 */ #include #include #include #define N 1007 using namespace std; int n,m,p,k,ans,cnt,tmp; int a[N],pos[N]; struct node{ int le... 阅读全文
摘要:
LI /* 没有考虑次大值有大于一个的情况 */ #include<iostream> #include<cstdio> #include<cstring> #define N 1000007 using namespace std; int n,m,ans,cnt,mx; int a[N]; in 阅读全文
摘要:
P3043 [USACO12JAN]牛联盟Bovine Alliance 题目描述 Bessie and her bovine pals from nearby farms have finally decided that they are going to start connecting th 阅读全文