"HDU 1241 链接" 连通块个数统计问题 选对一块油田八个方向进行dfs。 dfs的次数就是连通块的个数了,极度水题 ...
分类:
其他好文 时间:
2020-03-31 14:16:20
阅读次数:
50
题面见http://acm.hdu.edu.cn/showproblem.php?pid=3336 给你一个字符串,让你找它的前缀在整个字符串出现的次数。 作为一个不会思考的笨比,直接用kmp去一个个计数,果不其然,t了 找了博客来看,大概就是kmp+dp,要用到kmp中的pret数组(有的人习惯叫 ...
分类:
其他好文 时间:
2020-03-30 23:02:03
阅读次数:
65
Description "HDU 1160" FatMouse believes that the fatter a mouse is, the faster it runs. To disprove this, you want to take the data on a collection o ...
分类:
其他好文 时间:
2020-03-30 19:29:07
阅读次数:
76
题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=2732 题目给定一个场景,有n*m个方格,每个方格代表一个柱子,一个柱子可以承受不同次数的跳跃,开始时图中给定一些地方有蜥蜴,并且给定蜥蜴最多跳跃的步长,只要跳到方格之外就能安全,而且每只蜥蜴不能在同一个 ...
分类:
其他好文 时间:
2020-03-29 21:17:14
阅读次数:
77
动态开点线段树+dp。 题目转换成求$x_i$ include include include include include include include include include include include // include include include pragma GCC ...
分类:
其他好文 时间:
2020-03-29 11:02:31
阅读次数:
49
https://www.youtube.com/watch?v=H yTZFi _eY You solar system is a ticking time bomb Generations were born, live, and die, not knowing that the sun wil ...
分类:
其他好文 时间:
2020-03-29 01:44:58
阅读次数:
85
题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=1704 传递闭包定义在关系集R上,如果关系R中既有元组(x,y)又有元组(y,z)则元组(x,z),将这样的具有最小性的关系集合就是传递闭包。还有解释:传递闭包、即在数学中,在集合 X 上的二元关系 R ...
分类:
其他好文 时间:
2020-03-29 01:17:49
阅读次数:
58
卡特兰数又称卡塔兰数,英文名Catalan number,是组合数学中一个常出现在各种计数问题中出现的数列。以比利时的数学家欧仁·查理·卡塔兰 (1814–1894)的名字来命名,其前几项为(从第零项开始) : 1, 1, 2, 5, 14, 42, 132, 429, 1430, 4862, 16 ...
分类:
其他好文 时间:
2020-03-28 16:29:03
阅读次数:
100
[题目链接](https://vjudge.net/contest/364766 problem/C) 题目大意:每两个点之间只有一条边表示两点关系,关系具有传递性,问有多少点对之间没有关系。 这题利用了传递闭包来解。我们根据题目输入可以得到一条$a b$的边,表示$a$赢$b$,那么反过来我们也可 ...
分类:
其他好文 时间:
2020-03-28 13:38:53
阅读次数:
88
题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=1301 将结点的字符信息处理成点信息即可,代码如下: 1 #include<bits/stdc++.h> 2 using namespace std; 3 typedef unsigned int ui; ...
分类:
编程语言 时间:
2020-03-25 23:35:25
阅读次数:
84