码迷,mamicode.com
首页 >  
搜索关键字:lossy counting    ( 1053个结果
[HDU3518]Boring counting(后缀数组)
传送门 求出现超过1次的不重叠子串的个数 根据论文中的方法。 枚举子串的长度 k。 用 k 给 height 数组分组,每一组求解,看看当前组的位置最靠后的后缀和位置最靠前的后缀所差个数是否大于长度,大于的话 ans++。 分组思想需要认真体会一下。 ——代码 1 #include <cstdio> ...
分类:编程语言   时间:2017-06-11 10:28:00    阅读次数:198
SWJTU2017-6月月赛 G-A Easy Counting Problem[数论][乘法逆元]
传送门:http://www.swjtuoj.cn/problem/2397/ 题解:产生交点的条件为4个点构成四边形对角线产生交点,最大解当产生的交点位置完全不相同时存在。答案为$C_{\text{n}}^4$ 计算组合数时需要使用乘法逆元 代码: ...
分类:其他好文   时间:2017-06-11 10:09:42    阅读次数:147
counting sort
public class counting_sort { //O(n) it is stable(numbers with the same value appear in the output array in the same order as they do in the input //ar ...
分类:其他好文   时间:2017-06-06 22:16:02    阅读次数:206
[HDU]3518——Boring counting
zhan.jiang.ou now faced a tough problem,his english teacher quan.hong.chun gives him a string,which consists with n lower case letter,he must figure o ...
分类:其他好文   时间:2017-06-05 22:19:28    阅读次数:135
bzoj1630/2023 [Usaco2007 Demo]Ant Counting
传送门:http://www.lydsy.com/JudgeOnline/problem.php?id=1630 http://www.lydsy.com/JudgeOnline/problem.php?id=2023 【题解】 直接dp,f[i,j]表示第i个种族选了j只蚂蚁的方案数,转移枚举这个 ...
分类:其他好文   时间:2017-06-03 18:18:41    阅读次数:131
POJ 2386 Lake Counting(DFS)
题意:有一个大小为N×M的园子,雨后积起了水。八连通的积水被认为是连在一起的。求园子里一共有多少水洼? * * * * W* (八连通指的就是左图中相对W的*的部分) * * * Sample Input Sample Output ...
分类:其他好文   时间:2017-06-03 13:54:32    阅读次数:150
Instruments之Leaks学习
前言: 本篇文章,在于学习,我把别人的一些感觉好的文章汇总成了一篇,亲自实现了一下,留用于今后学习资料。 文章脉络: 文章脉络: 简介:Objective_C 有3种内存管理方法, 它们分别是 1>MRR① 也称为 MRC(Manual Reference Counting, 手动引用计数)② 由程 ...
分类:其他好文   时间:2017-06-02 15:47:13    阅读次数:285
POJ 2386 Lake Counting
来源:http://poj.org/problem?id=2386 Lake Counting Time Limit: 1000MS Memory Limit: 65536K Total Submissions: 20124 Accepted: 10139 Description Due to re ...
分类:其他好文   时间:2017-06-02 11:44:54    阅读次数:183
HNU13303 Counting substhreengs(递推)
题目:http://acm.hnu.cn/online/?action=problem&type=show&id=13303&courseid=0 题意:给你一个字符串,由数字和其它字符组成,问有多少个子串,使得子串里面的数字和为3的整数倍(子串必须连续,并且里面不能有其它字符)。 分析:开3个数组 ...
分类:其他好文   时间:2017-05-31 14:06:43    阅读次数:158
Lake Counting (POJ No.2386)
Description Due to recent rains, water has pooled in various places in Farmer John's field, which is represented by a rectangle of N x M (1 <= N <= 10 ...
分类:其他好文   时间:2017-05-28 20:52:18    阅读次数:204
1053条   上一页 1 ... 37 38 39 40 41 ... 106 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!