Loading

摘要: 题目链接: https://www.acwing.com/problem/content/1103/ 题解: !!! 要么在bfs内部定义queue,要么每次在进入bfs时将queue清空!!!! AC代码:#include <cstdio> #include <cstring> #include 阅读全文
posted @ 2020-02-28 19:49 Doubest 阅读(163) 评论(0) 推荐(0) 编辑
摘要: 题目链接: https://www.acwing.com/problem/content/1240/ 题解: 双指针算法,注意率先移动前向的指针,当前向指针的时间-后向指针的时间超过了规定时间的话,后项指针要移动到该区间里才行 AC代码: #include <cstdio> #include <cs 阅读全文
posted @ 2020-02-28 19:15 Doubest 阅读(183) 评论(0) 推荐(0) 编辑