The contest’s message distribution is a big thing in prepare. Assuming N students stand in a row, from the row-head start transmit message, each perso ...
分类:
其他好文 时间:
2019-09-30 14:58:16
阅读次数:
101
Friend HDU - 1719 Friend number are defined recursively as follows. (1) numbers 1 and 2 are friend number; (2) if a and b are friend numbers, so is ab ...
分类:
其他好文 时间:
2019-09-30 14:40:25
阅读次数:
114
Problem DescriptionIn many applications very large integers numbers are required. Some of these applications are using keys for secure transmission of ...
分类:
其他好文 时间:
2019-09-29 23:35:48
阅读次数:
121
Problem DescriptionI have a very simple problem for you. Given two integers A and B, your job is to calculate the Sum of A + B. InputThe first line of ...
分类:
其他好文 时间:
2019-09-29 23:23:17
阅读次数:
100
题:http://acm.hdu.edu.cn/showproblem.php?pid=6736 题意:删掉一些边使得图不存在点双,求方案数。 分析:若一条边不属于点双,那么这条边有删和不删俩种选择,若找到点双,点双中必须删掉一条边(题目有保证一条边只能属于一个点双,所以不用担心一条边用于多个点双) ...
分类:
其他好文 时间:
2019-09-29 21:37:40
阅读次数:
93
题目链接: http://acm.hdu.edu.cn/showproblem.php?pid=6736 题意: 在给定图中寻找所有最小环 保证不存在一条边经过两个简单环 数据范围: $1\leq n \leq 300 000$ $1\leq m \leq 500 000$ 分析: 依次把点加入栈中 ...
分类:
其他好文 时间:
2019-09-28 19:54:04
阅读次数:
196
博文:https://blog.csdn.net/yjr3426619/article/details/82315133 带全并查集 路径压缩,表达每个当前node与 当前node所在的并查集的root 之间的关系 并查集一定是单向连通的,所以一些node处理时 【node1,node2】 weig ...
分类:
其他好文 时间:
2019-09-28 14:43:47
阅读次数:
70
"题目描述" 思路 bfs主要问题就是走重复路的问题,需要设置一个vis数组防止走重复路,怎么把一个二维数组表示成一个数,扩展来说就是怎么把状态表示成一个数,看了别人的代码,可以二进制的数来记录状态,4x4的数组状态不会超过2^(17)。 然后就是怎么走的问题,规定只能向下,下右走,而向上,向左就是 ...
分类:
其他好文 时间:
2019-09-28 12:43:23
阅读次数:
61
题目链接 :http://acm.hdu.edu.cn/showproblem.php?pid=1506 Problem Description A histogram is a polygon composed of a sequence of rectangles aligned at a co ...
分类:
其他好文 时间:
2019-09-28 12:43:03
阅读次数:
68
hdu 6599 I Love Palindrome String 回文自动机 当个回文自动机的模板 题意 给一个串S,求长度为i的“特殊回文串”个数,“特殊回文串”要求是回文串,并且自己的一半也是回文串。 思路 求回文串个数相关,优先考虑使用回文自动机,“特殊回文串”要求是回文串,并且自己的一半也 ...
分类:
其他好文 时间:
2019-09-27 21:12:14
阅读次数:
54