题解
maxfield_zhu
这个作者很懒,什么都没留下…
展开
-
幅優先探索(题解)
幅優先探索(atcoder)题解一、题目描述给你一个迷宫,有障碍物,请问最少多少步才能走出迷宫(宽搜基础题)二、算法使用宽搜使用队列 + pair(或struct),或深搜也行,就是一步步向下扩展三、题解代码如下:#include <bits/stdc++.h>using namespace std;char ch[101][101];int flag[101][101];int dx[5] = {0 , 0 , 1 , -1};//定义四个方向int dy[5]原创 2021-06-20 21:02:24 · 108 阅读 · 0 评论 -
codeforces268B
codeforces Problem 268B难题不会做,只会刷水题Manao is trying to open a rather challenging lock. The lock has n buttons on it and to open it, you should press the buttons in a certain order to open the lock. When you push some button, it either stays pressed into th原创 2020-12-23 22:16:10 · 220 阅读 · 0 评论