随笔分类 -  DFS

摘要:Problem 求 [1N]中素因子数最多且最小的数 nN 充分大。 Solution 将任意自然数 n (n>2) 分解 $$ n = p_1^{k_1 } p_2^{k_2} p_3^{k_3} \dots P_m^{k_m} \quad (p_1<p_2< 阅读全文
posted @ 2016-11-22 12:02 Pat 阅读(387) 评论(0) 推荐(0) 编辑
摘要:2016 CCPC 东北四省赛 D. 一道好题. 现场写崩了. 赛后LSh跟我讲了一种离散化的做法, 没听懂. 题意 一个RC (R,C109) 的矩形点阵上有 n (n200) 个坏点, 其余都是好点. 求 好点的4 连通块 (以下简称cell) 阅读全文
posted @ 2016-10-21 19:57 Pat 阅读(270) 评论(0) 推荐(0) 编辑
摘要:传送门 Given an integer n, for all integers not larger than n, find the integer with the most divisors. If there is more than one integer with the same n 阅读全文
posted @ 2016-03-19 21:13 Pat 阅读(290) 评论(0) 推荐(0) 编辑
摘要:传送门Time Limit: 3000MSDescriptionThere is a magic planet in the space. There is a magical country on the planet. There are N cities in the country. The... 阅读全文
posted @ 2015-10-13 09:36 Pat 阅读(228) 评论(0) 推荐(0) 编辑
摘要:传送门 Time Limit:1000MS Memory Limit:32768KB 64bit IO Format:%I64d & %I64u Description A school bought the first computer some time ago(so this computer 阅读全文
posted @ 2015-10-13 08:53 Pat 阅读(363) 评论(0) 推荐(0) 编辑
摘要:传送门WORDS1 - Play on Words#graph-theory#euler-circuitSome of the secret doors contain avery interesting word puzzle. The team of archaeologists has to ... 阅读全文
posted @ 2015-09-18 20:48 Pat 阅读(259) 评论(0) 推荐(0) 编辑
摘要:传送门Closest Common AncestorsTime Limit:2000MSMemory Limit:10000KTotal Submissions:17306Accepted:5549DescriptionWrite a program that takes as input a ro... 阅读全文
posted @ 2015-08-13 19:38 Pat 阅读(191) 评论(0) 推荐(0) 编辑
摘要:传送门考研路茫茫——空调教室Time Limit: 4000/2000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 2445Accepted Submission(s): 720Probl... 阅读全文
posted @ 2015-08-13 12:40 Pat 阅读(304) 评论(0) 推荐(0) 编辑
摘要:这是DFS系列的第二篇 割边的概念 In graph theory, a bridge, isthmus, cut-edge, or cut arc is an edge of a graph whose deletion increases its number of connected comp 阅读全文
posted @ 2015-08-08 16:53 Pat 阅读(4855) 评论(0) 推荐(0) 编辑
摘要:传送门:1400 序列分解序列分解 基准时间限制:1s 空间限制:131072 KBKB131072 KB 1 秒 空间限制:131072 KB 分值: 40 难度:4级算法题1 秒 空间限制:131072 KB 分值: 40 难度:4级算法题 小刀和大刀是双胞胎兄弟。今天他们玩一个有意思的游戏。 阅读全文
posted @ 2015-07-26 09:29 Pat 阅读(412) 评论(0) 推荐(0) 编辑

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