随笔分类 -  BFS

摘要:题目来自“2018-2019 ICPC, NEERC, Southern Subregional Contest”,codeforces上放置了此题:Find a Number 题意:给出两个正整数d,s。找到一个最小的数 n 使得 n%d==0,并且所有的 n 所有位的数字相加和为s。 解题思路: 阅读全文
posted @ 2021-05-25 17:33 ISGuXing 阅读(134) 评论(0) 推荐(0) 编辑
摘要:题目链接:https://www.nowcoder.com/acm/contest/96/G 思路:两遍bfs,找到p到k的情况,记录时间;找到E到k的情况,记录时间。题目超时点在于输入需要用scanf。如果不用scanf可以用cin加速挂。 AC代码: 阅读全文
posted @ 2018-04-20 10:20 ISGuXing 阅读(300) 评论(0) 推荐(0) 编辑
摘要:C. Ice Cave time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output You play a computer game. Yo 阅读全文
posted @ 2017-10-09 22:44 ISGuXing 阅读(282) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示