摘要: #include<bits/stdc++.h> using namespace std; int n; int a[4][27]; int b[4][27]; int m[27]; int search(int l) { for(int i=0;i<10;i++) { m[l]=i; for(int 阅读全文
posted @ 2022-03-20 11:11 映波yoyo 阅读(23) 评论(0) 推荐(0) 编辑
摘要: 王先生想要一些男孩帮助他做一个项目。因为项目比较复杂,男生来的越多越好。当然也有一定的要求。 王先生选了一个足够容纳男孩子的房间。没有被选中的男孩必须立即离开房间。房间里一开始就有1000万男孩,编号从1到1000万。王先生选了以后,在这间屋子里的任何两个都应该是朋友(直接或间接),否则就只剩下一个 阅读全文
posted @ 2021-12-19 11:46 映波yoyo 阅读(55) 评论(0) 推荐(0) 编辑
摘要: #include<bits/stdc++.h>using namespace std;struct node{ char lc,rc,fa;};node tree[1000];void work(char s){ cout<<s; if(tree[s].lc!='*')work(tree[s].lc 阅读全文
posted @ 2021-08-12 15:40 映波yoyo 阅读(20) 评论(0) 推荐(0) 编辑
摘要: #include<bits/stdc++.h>using namespace std;struct Node{ int data; Node *next;};Node *head,*p,*r;int x;int main(){ cin>>x; head=new Node; r=head; while 阅读全文
posted @ 2021-08-10 10:55 映波yoyo 阅读(15) 评论(0) 推荐(0) 编辑
摘要: #include<bits/stdc++.h>using namespace std;int k[201];int h[10001];//队列 int p[10001];//记录按第几次 int c[201];//标记是否走过 int n,a,b;int bfs(){ int head=0,tail 阅读全文
posted @ 2021-08-08 17:25 映波yoyo 阅读(93) 评论(0) 推荐(0) 编辑
摘要: #include<bits/stdc++.h>using namespace std;int u[4]={0,1,0,-1};int v[4]={1,0,-1,0};int r,c;int book[45][45];char mg[45][45];void zmg(){ int dl[1605][3 阅读全文
posted @ 2021-04-18 10:03 映波yoyo 阅读(71) 评论(0) 推荐(0) 编辑
摘要: #include<bits/stdc++.h>using namespace std;int h[10001][3];int n,m,num=0;int dj[101][101];int u[4]={0,1,0,-1};int v[4]={1,0,-1,0};void gs(int p,int q) 阅读全文
posted @ 2021-04-11 12:06 映波yoyo 阅读(106) 评论(0) 推荐(0) 编辑
摘要: #include<bits/stdc++.h>using namespace std;int ju[9][9]={{0,0,0,0,0,0,0,0,0}, {0,1,0,0,0,1,0,1,1}, {0,0,1,1,1,1,0,1,1}, {0,0,1,1,0,0,1,1,1}, {0,0,1,0, 阅读全文
posted @ 2021-04-11 10:47 映波yoyo 阅读(49) 评论(0) 推荐(0) 编辑
摘要: //八皇后(数字串)#include<bits/stdc++.h>using namespace std;int a[9],k[93][8];bool b[9],c[17],d[17];int num;int zr(){ num++; for(int i=1;i<=8;i++) { k[num][i 阅读全文
posted @ 2021-02-05 17:37 映波yoyo 阅读(16) 评论(0) 推荐(0) 编辑
摘要: //LETTERS#include<bits/stdc++.h>using namespace std;int u[4]={-1,0,1,0};int v[4]={0,1,0,-1};bool b[27];char a[21][21];int r,s,max1;int search(int m,in 阅读全文
posted @ 2021-02-05 17:35 映波yoyo 阅读(34) 评论(0) 推荐(0) 编辑