上一页 1 ··· 4 5 6 7 8 9 10 11 12 ··· 17 下一页
摘要: http://ybt.ssoier.cn:8088/problem_show.php?pid=1256 1 #include<bits/stdc++.h> 2 using namespace std; 3 int t, row, col; 4 char mp[205][205]; 5 int dir 阅读全文
posted @ 2020-10-02 12:30 TFLSNOI 阅读(495) 评论(0) 推荐(0) 编辑
摘要: http://ybt.ssoier.cn:8088/problem_show.php?pid=1250 此题目难点: 1.利用二进制的与运算判断与隔壁房间是否有墙,从而求出下一步的方向 2.与运算的优先性 3.代码的调试 1 #include<bits/stdc++.h> 2 using names 阅读全文
posted @ 2020-09-30 21:15 TFLSNOI 阅读(537) 评论(0) 推荐(0) 编辑
摘要: http://ybt.ssoier.cn:8088/problem_show.php?pid=1249&teacher=2 1 #include<bits/stdc++.h> 2 using namespace std; 3 int n, m; 4 char mp[120][120]; 5 int 阅读全文
posted @ 2020-09-30 15:52 TFLSNOI 阅读(403) 评论(0) 推荐(0) 编辑
摘要: 题目链接:http://ybt.ssoier.cn:8088/problem_show.php?pid=1257 1 #include<bits/stdc++.h> 2 using namespace std; 3 int n, l; 4 int sx, sy; 5 int ex, ey; 6 st 阅读全文
posted @ 2020-09-30 10:46 TFLSNOI 阅读(337) 评论(0) 推荐(0) 编辑
摘要: http://ybt.ssoier.cn:8088/problem_show.php?pid=1360 1 #include<bits/stdc++.h> 2 using namespace std; 3 int n, a, b; 4 int k[205]; 5 bool vis[205]; 6 s 阅读全文
posted @ 2020-09-30 08:48 TFLSNOI 阅读(680) 评论(0) 推荐(0) 编辑
摘要: http://ybt.ssoier.cn:8088/problem_show.php?pid=1253 1 #include<bits/stdc++.h> 2 using namespace std; 3 int n, k; 4 struct node{ //结构体表示数轴位置和所用时间 5 int 阅读全文
posted @ 2020-09-29 23:19 TFLSNOI 阅读(617) 评论(0) 推荐(0) 编辑
摘要: 题目链接:http://ybt.ssoier.cn:8088/problem_show.php?pid=1251 1 #include<bits/stdc++.h> 2 using namespace std; 3 int m, n; 4 char mp[25][25]; 5 int sx, sy, 阅读全文
posted @ 2020-09-29 22:42 TFLSNOI 阅读(829) 评论(0) 推荐(0) 编辑
摘要: http://ybt.ssoier.cn:8088/problem_show.php?pid=1330 1 #include<bits/stdc++.h> 2 using namespace std; 3 int ax, ay, bx, by; 4 struct node{ //结构体标记当前位置坐 阅读全文
posted @ 2020-09-28 23:25 TFLSNOI 阅读(1231) 评论(0) 推荐(0) 编辑
摘要: http://ybt.ssoier.cn:8088/problem_show.php?pid=1329 方法一:DFS 1 #include<bits/stdc++.h> 2 using namespace std; 3 int n, m; 4 char c; 5 char a[1000][1000 阅读全文
posted @ 2020-09-26 22:55 TFLSNOI 阅读(620) 评论(0) 推荐(0) 编辑
摘要: 题目链接http://ybt.ssoier.cn:8088/problem_show.php?pid=1216 方法一:DFS 1 #include<bits/stdc++.h> 2 using namespace std; 3 int w, h; //h代表行数, w代表列数 4 int sx, 阅读全文
posted @ 2020-09-22 11:09 TFLSNOI 阅读(1056) 评论(0) 推荐(0) 编辑
摘要: 题目链接:http://ybt.ssoier.cn:8088/problem_show.php?pid=1217 1 #include <bits/stdc++.h> 2 const int max_n=10; 3 using namespace std; 4 bool vis[max_n];//记 阅读全文
posted @ 2020-09-21 23:58 TFLSNOI 阅读(560) 评论(0) 推荐(0) 编辑
摘要: “回溯法”也称“试探法”。它是从问题的某一状态出发,不断“试探”着往前走一步,当一条路走到“尽头”,不能再前进(拓展出新状态)的时候,再倒回一步或者若干步,从另一种可能的状态出发,继续搜索,直到所有的“路径(状态)”都一一试探过。这种不断前进、不断回溯,寻找解的方法,称为“回溯法”。 他的基本思想是 阅读全文
posted @ 2020-09-18 10:31 TFLSNOI 阅读(3049) 评论(0) 推荐(0) 编辑
摘要: 题目链接:http://ybt.ssoier.cn:8088/problem_show.php?pid=1318 方法一:DFS 1 #include<bits/stdc++.h> 2 using namespace std; 3 int ans[21]; //用于存放答案 4 int n, tot 阅读全文
posted @ 2020-09-18 09:00 TFLSNOI 阅读(805) 评论(0) 推荐(0) 编辑
摘要: 一、DFS实现N皇后 1 #include<bits/stdc++.h> 2 using namespace std; 3 int ans[10];//用于存放答案 4 int tot;//方案数 5 const int n=8;//N皇后问题 6 bool check(int c, int r){ 阅读全文
posted @ 2020-09-17 23:32 TFLSNOI 阅读(225) 评论(0) 推荐(0) 编辑
摘要: 题目链接:https://blog.csdn.net/wly_2014/article/details/51388263 1 #include<bits/stdc++.h> 2 using namespace std; 3 const int maxn=64; 4 int n, matchlist[ 阅读全文
posted @ 2020-08-22 11:19 TFLSNOI 阅读(153) 评论(0) 推荐(0) 编辑
上一页 1 ··· 4 5 6 7 8 9 10 11 12 ··· 17 下一页