#Loves

A. DZY Loves Sequences

题目链接:http://codeforces.com/problemset/problem/446/A 题目大意:让你找到一个区间,你可以改变这个区间的一个数,然后使得这个区间是严格上升的且这个区间一定是最长的,输出区间长度 思路:用dp1[i]记录i之前(包括i自己)连续序列长度(不一定是最长的)用dp2[i]记录i...
代码星球 代码星球·2023-05-06

Codeforces444A_DZY Loves Physics

DZYLovesPhysicstimelimitpertest1secondmemorylimitpertest256megabytesinputstandardinputoutputstandardoutputDZYlovesPhysics,andheenjoyscalculatingdensity.Almostev...

BZOJ3561 DZY Loves Math VI 数论 快速幂 莫比乌斯反演

原文链接http://www.cnblogs.com/zhouzhendong/p/8116330.htmlUPD(2018-03-26):回来重新学数论啦。之前的博客版面放在更新之后的后面。  给出$n,m$,求$Largesum_{i=1}^nsum_{j=1}^mlcm(i,j)^{gcd(i,j)}$。  $1...

BZOJ3560 DZY Loves Math V 数论 快速幂

原文链接http://www.cnblogs.com/zhouzhendong/p/8111725.htmlUPD(2018-03-26):蒟蒻回来重新学数论了。更新了题解和代码。之前的怼到后面去了。  给定$n$个正整数$a_1,a_2,a_3,...,a_n$,求  $$Hugesum_{i_1|a_1}sum_{...

hdoj5645DZY Loves Balls

ProblemDescriptionDZYlovesplayingballs.Hehas n ballsinabigbox.Oneachballthereisanintegerwritten.Onedayhedecidestopicktwoballsfromthebox.Firstherandoml...
代码星球 代码星球·2020-04-06