数学
文章平均质量分 89
yasolx
ACMer
展开
-
HDU 4405 Aeroplane chess(概率dp)
Aeroplane chessTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 3119 Accepted Submission(s): 1993Problem DescriptionHzz loves aero原创 2016-07-13 16:54:19 · 534 阅读 · 0 评论 -
进制转换(-R进制)
1004: 进制转换(-R进制)Time Limit: 1 Sec Memory Limit: 128 MB 64bit IO Format: %lldSubmitted: 3 Accepted: 1[Submit][Status][Web Board]Description 我们可以用这样的方式来表示一个十进制数: 将每个阿拉伯数字乘以一个以该数字所处位置原创 2017-03-06 10:29:40 · 3695 阅读 · 0 评论 -
POJ 1930 Dead Fraction (无限循环小数转化为分数)
Dead FractionTime Limit: 1000MS Memory Limit: 30000KTotal Submissions: 2597 Accepted: 845DescriptionMike is frantically scrambling to finish his thesis at the last原创 2016-07-15 16:23:40 · 562 阅读 · 0 评论 -
HDU 5723 Abandoned country (最小生成树+期望)
Abandoned countryTime Limit: 8000/4000 MS (Java/Others) Memory Limit: 65536/65536 K (Java/Others)Total Submission(s): 2226 Accepted Submission(s): 572Problem DescriptionAn abandoned原创 2016-07-20 21:25:20 · 507 阅读 · 0 评论 -
HDU 4965 Fast Matrix Calculation(矩阵快速幂)
Fast Matrix CalculationTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 131072/131072 K (Java/Others)Total Submission(s): 1700 Accepted Submission(s): 784Problem DescriptionO原创 2017-07-15 19:14:14 · 352 阅读 · 0 评论 -
UVA 11149 Power of Matrix(求幂函数的前n项和)
题目大意: 给你一个矩阵A,求A^1+A^2+A^3+...+A^n解题思路: 利用和快速幂一样的思想,我们可以对原式变形。 当n为偶数的时候: 当n为奇数的时候: 所以,我们就可以用递归每次先求出n/2的前n项和,然后利用矩阵快速幂和上面的式子得到前n项和。时间复杂度为O(logn*logn)。AC代码:原创 2017-07-15 20:52:17 · 904 阅读 · 0 评论 -
HDU 6071 Lazy Running(同余+最短路)
Lazy RunningTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 524288/524288 K (Java/Others)Total Submission(s): 287 Accepted Submission(s): 126Problem DescriptionIn HDU, you h原创 2017-08-04 15:13:36 · 1486 阅读 · 5 评论 -
ZOJ 3424 Rescue(和式变形递推公式降低复杂度)
Rescue Time Limit: 3 Seconds Memory Limit: 65536 KB The princess is trapped in a magic place. In this place, there are N magic stones. In order to rescue the princess, you should destroy all the原创 2017-08-29 19:46:01 · 616 阅读 · 0 评论 -
Codeforces 842C Ilya And The Tree(树上DP+因子个数估计)
C. Ilya And The Tree time limit per test2 seconds memory limit per test256 megabytes inputstandard input outputstandard output Ilya is very fond of graphs, especially trees. During his last trip t原创 2017-08-30 11:05:57 · 1399 阅读 · 4 评论 -
hihoCoder 1473 小Ho的强迫症(加法取模)
时间限制:10000ms单点时限:1000ms内存限制:256MB描述小Ho在一条笔直的街道上散步。街道上铺着长度为L的石板,所以每隔L距离就有一条石板连接的缝隙,如下图所示。小Ho在散步的时候有奇怪的强迫症,他不希望脚踩在石板的缝隙上。(如果小Ho一只脚的脚尖和脚跟分别处于一条缝隙的两侧,我们就认为他踩在了缝隙上。如果只有脚尖或脚跟接触缝隙,不原创 2017-03-05 15:45:46 · 1317 阅读 · 0 评论 -
Codeforces Round 718C(维护矩阵的线段树)
C. Sasha and Arraytime limit per test5 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputSasha has an array of integers a1, a2, ..., an. Yo原创 2016-09-25 15:51:04 · 1371 阅读 · 0 评论 -
HDU 3608 0 or 1(求一个数因子和的奇偶)
0 or 1Time Limit: 6000/2000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 3460 Accepted Submission(s): 988Problem DescriptionSolving problem is a int原创 2016-08-26 09:45:45 · 804 阅读 · 0 评论 -
HDU 3029 Scales(三进制)
ScalesTime Limit: 6000/3000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 517 Accepted Submission(s): 233Problem DescriptionGive you a scale, a goods原创 2016-07-10 20:46:19 · 709 阅读 · 0 评论 -
POJ 3370 Halloween treats(抽屉原理)
Every year there is the same problem at Halloween: Each neighbour is only willing to give a certain total number of sweets on that day, no matter how many children call on him, so it may happen that a child will get nothing if it is too late. To avoid conf原创 2016-07-10 21:07:06 · 496 阅读 · 0 评论 -
POJ 3421 X-factor Chains (整数分解+组合数)
X-factor ChainsTime Limit: 1000MS Memory Limit: 65536KTotal Submissions: 6496 Accepted: 2018DescriptionGiven a positive integer X, an X-factor chain of length原创 2016-07-15 21:20:01 · 869 阅读 · 0 评论 -
HDU 5792 World is Exploding (容斥原理+离散化+树状数组)
World is ExplodingTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/65536 K (Java/Others)Total Submission(s): 330 Accepted Submission(s): 151Problem DescriptionGiven a seque原创 2016-08-03 09:01:05 · 736 阅读 · 0 评论 -
Codeforces 707C Pythagorean Triples(已知直角三角形一边求另两边)
C. Pythagorean Triplestime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputKatya studies in a fifth grade. Recently her cl原创 2016-08-21 07:52:47 · 1657 阅读 · 0 评论 -
Codeforces 233C Partial Sums(特殊三角矩阵压缩)
C. Partial Sumstime limit per test4 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputYou've got an array a, consisting of n integers. Th原创 2016-09-02 14:46:12 · 781 阅读 · 0 评论 -
ZOJ 1136&&POJ 1465 Multiple(BFS+同余定理)
MultipleTime Limit: 1000MS Memory Limit: 32768KTotal Submissions: 7215 Accepted: 1546Descriptiona program that, given a natural number N between 0 and 4999 (inclusi原创 2016-08-17 20:04:49 · 674 阅读 · 0 评论 -
POJ 3420 Quad Tiling(轮廓线DP+矩阵快速幂)
Quad TilingTime Limit: 1000MS Memory Limit: 65536KTotal Submissions: 4076 Accepted: 1856DescriptionTired of the Tri Tiling game finally, Michael turns to a more原创 2016-08-24 09:44:15 · 1202 阅读 · 1 评论 -
Codeforces 845G Shortest Path Problem?(异或最短路)
G. Shortest Path Problem?time limit per test3 secondsmemory limit per test512 megabytesinputstandard inputoutputstandard outputYou are given an undirected graph原创 2017-08-28 14:05:31 · 2572 阅读 · 3 评论