02 2022 档案
摘要:code #include<iostream> #include<cstring> #include<cstdlib> using namespace std; typedef struct SColor{ char w[21]; int v; }Color; Color color[1000],m
阅读全文
摘要:code #include<iostream> #include<algorithm> using namespace std; int main(){ int n,t,s,m,h; scanf("%d",&n); while(n--){ scanf("%d",&t); s=t%60; t/=60;
阅读全文
摘要:code #include<iostream> #include<algorithm> using namespace std; typedef struct Student{ char name[21],gender[21]; int age,grade; }student; int main()
阅读全文
摘要:code #include<iostream> #include<cstring> using namespace std; int main() { ios::sync_with_stdio(false); cin.tie(NULL); int i, n; char sa[10000], sb[1
阅读全文
摘要:code #include<iostream> using namespace std; int main() { int is_leap_year(int); int year_days(int);//one year have days int month_days(int); int week
阅读全文
摘要:code #include<iostream> #include<complex> #include<cstdlib> using namespace std; int is_p(int);//judge sqrt int is_pp(int); int main(){ ios::sync_with
阅读全文
摘要:
阅读全文
摘要:
阅读全文
摘要:code #include<iostream> #include<algorithm> #include<cstdlib> using namespace std; const int MN = 101; char s[MN][MN]; int N, starX, starY, endX, endY
阅读全文
摘要:code #include<iostream> using namespace std; char s[100000]; int main(){ ios::sync_with_stdio(false); cin.tie(nullptr); int i,x,m,n;//x->comment state
阅读全文
摘要:code #include<iostream> #include<algorithm> #include<cstring> using namespace std; const int N=200000; char s[N]; int main(){ int l,m; char *t,*w; if(
阅读全文
摘要:code #include<iostream> #include<cstring> #include<complex> #include<cstdlib> #include<ctype.h> typedef struct SGrid{ char s[20]; int p[4]; double r;
阅读全文
摘要:
阅读全文
摘要:code #include<iostream> #include<algorithm> using namespace std; int main(){ int i,n,t,a[101]; scanf("%d",&n); for(i=n;i>=0;--i){ scanf("%d",&a[i]); }
阅读全文
摘要:
阅读全文
摘要:code #include<algorithm> #include<iostream> #include<complex> using namespace std; const int maxn=10,N=8; int place[maxn];//queens' place,from 1 bool
阅读全文
摘要:code #include<algorithm> #include<iostream> #include<cstring> using namespace std; const int MIN=-0x3f3f3f3f,maxn=35; int N,M,val[maxn],dp[maxn][maxn]
阅读全文
摘要:code #include<iostream> #include<vector> #include<cstring> #include<algorithm> using namespace std; int N, P; const int maxn = 310; bool isRemoved[max
阅读全文
摘要:tie是将两个stream绑定的函数,空参数的话返回当前的输出流指针。 std :: cin默认是与std :: cout绑定的,所以每次操作的时候都要调用fflush,这样增加了IO的负担,通过tie(nullptr)来解除std :: cin和std :: cout之间的绑定,进一步加快执行效率
阅读全文
摘要:code #include<algorithm> #include<iostream> using namespace std; void iswap(int a[],int x,int y){ if(a[x]==a[y]){ return; }else{ swap(a[x],a[y]); } }
阅读全文
摘要:
阅读全文
摘要:code #include<algorithm> #include<iostream> #include<cstring> using namespace std; int main(){ ios::sync_with_stdio(false); char s1[105],s2[105];//sto
阅读全文
摘要: 
阅读全文
摘要:code #include<cstring> #include<iostream> #include<vector> #include<sstream> #include<algorithm> #include<iomanip> using namespace std; struct Node{ s
阅读全文
摘要:code #include<iostream> #include<algorithm> using namespace std; const int N=1000+10; bool cmp(int x,int y){ return x>y; } int f1[N],f2[N]; int main()
阅读全文
摘要:code #include<cstdio> #include<algorithm> #include<iostream> using namespace std; void tran(int t){ if(t==0){ //TODO cout<<"00:00:00\n"; return; } int
阅读全文
摘要:code #include<iostream> using namespace std; typedef long long LL; const int N=1500000,M=100010; int vis[N],prime[M]; LL f[M]; int main(){ ios::sync_w
阅读全文
摘要:code #include<iostream> #include<algorithm> using namespace std; int len; string s; void recursion(int l,int r){ if(l==r||l>(len-1)/2){//single charac
阅读全文
摘要:code #include<iostream> #include<cstdio> using namespace std; int main() { ios::sync_with_stdio(false); int a,m,ans; cin>>a>>m; a%=m; ans=a*a%m; cout<
阅读全文
摘要:code #include<iostream> #include<cstdio> using namespace std; int main() { ios::sync_with_stdio(false); int n; cin >> n; if (n & 1) { printf("odd"); /
阅读全文
摘要:视频解说 所需软件: TCPOptimizer
阅读全文
摘要:code #include<iostream> #include<algorithm> using namespace std; const int N=2; int m; struct Matrix{ int m[N][N]; }matrix;//definr matrix struct Matr
阅读全文
摘要:快速排序的特点 元素越无序,时间效率就越高 空间复杂度 快速排序空间复杂度为 code #include<iostream> using namespace std; void QuickSort(int a[],int L,int R); int main(){ ios::
阅读全文
摘要:code #include<iostream> #include<algorithm> #include<vector> using namespace std; int main(){ ios::sync_with_stdio(false); int C; vector<int> vec; whi
阅读全文
摘要:~在C语言的意思是按位取反,即0->1,1->0. 而且scanf函数是有返回值的,并且返回值为int。 根据这个符号特殊的含义和scanf函数的返回值,当输入为-1是,将-1取反为0,循环会结束 所以~的含义为循环输入,直到输入-1,停止循环。
阅读全文
摘要:code #include<iostream> #include<string> #include<algorithm> using namespace std; int main(){ ios::sync_with_stdio(false); string str; getline(cin,str
阅读全文
摘要:code #include<iostream> #define min(a,b)a>b?b:a using namespace std; int n, m, a[25502], b[100]; int main() { ios::sync_with_stdio(false); cin >> n >>
阅读全文
摘要:code #include<algorithm> #include<iostream> #include<complex> using namespace std; int main(){ ios::sync_with_stdio(false); int n,m; cin>>n>>m; int a[
阅读全文
摘要:code #include<algorithm> #include<iostream> using namespace std; bool check(int i){ int a=i,b=i+1,c=i+2; while(a||b||c){ //TODO test carry bit if((a%1
阅读全文
摘要:code #include<iostream> using namespace std; int a[11][11], b[11], bj[11] = {0}, n, k, sum = 0; int f(int s) { int i1; if (s == n) { sum++; if (sum ==
阅读全文
摘要:code #include<algorithm> #include<iostream> using namespace std; int a[105], b, n; int main() { ios::sync_with_stdio(false); while (cin >> n >> b) { /
阅读全文
摘要:code #include<iostream> #include<algorithm> #include<complex> #include<cstring> using namespace std; const int N=10000; double a[N],b[N],c[N],d[N],e[N
阅读全文
摘要:https://www.cnblogs.com/walfud/articles/2047096.html cout格式化输出 cout输出精度、位数
阅读全文
摘要:code #include<iostream> #include<algorithm> using namespace std; int cnt = 0 ; void fun(int n, int m, char a, char b, char c) { if (n <= m) { cnt++; }
阅读全文
摘要:software remove and so on
阅读全文
摘要:code #include<algorithm> #include<iostream> using namespace std; int main(){ ios::sync_with_stdio(false); float n,x,sum=0; cin>>x; int i; while(0!=x){
阅读全文