
BFS
S_Black
学生
展开
-
【HDU】 1241 Oil Deposits
Oil DepositsTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 20535 Accepted Submission(s): 11816Problem DescriptionThe GeoSurvComp原创 2016-01-19 09:32:42 · 404 阅读 · 0 评论 -
【HDU】 1242 Rescue
RescueTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 23012 Accepted Submission(s): 8134Problem DescriptionAngel was caught by th原创 2016-01-19 09:37:45 · 361 阅读 · 0 评论 -
【HDU】 1312 Red and Black
Red and BlackTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 14637 Accepted Submission(s): 9070Problem DescriptionThere is a rect原创 2016-01-19 09:45:34 · 355 阅读 · 0 评论 -
【HDU】 1026 Ignatius and the Princess I
Ignatius and the Princess ITime Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 15512 Accepted Submission(s): 4909Special JudgeProblem D原创 2016-01-19 09:49:27 · 430 阅读 · 0 评论 -
【HDU】 1180 诡异的楼梯
诡异的楼梯Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 131072/65536 K (Java/Others)Total Submission(s): 11508 Accepted Submission(s): 2854Problem DescriptionHogwarts正式开学以后,Harry发现原创 2016-01-19 16:31:49 · 503 阅读 · 0 评论 -
【HDU】 1973 Prime Path
Prime Path题目链接Prime Path题目大意 现在给你两个素数a,b.要你每次只能改变一位,而且每次得到的数必须是素数,现在让你求一个最小步数,从a到b最少需要这样操作多少次。题解 最小步数,每次只能改变一位,想到直接BFS,因为数据很小,1000到10000之间素数也不会很多(打表发现仅有1061个),于是直接打表然后建边,从a开始BFS搜到B。代码#include <原创 2016-07-04 18:14:55 · 572 阅读 · 0 评论