
数学
文章平均质量分 71
nare123
这个作者很懒,什么都没留下…
展开
-
Codeforces 687B - Remainders Game (剩余定理)
B. Remainders Gametime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputToday Pari and Arya are playing a game ca原创 2016-07-22 15:59:18 · 475 阅读 · 0 评论 -
HDU 5674 Function(斐波那契模数列循环节)
Problem Description There is a function f(n)=(a+√b)^n+(a−√b)^n. a and b are integers (1≤a,b≤1,000,000). Maybe the function looks complex but it is actually an integer.The question is to calculate原创 2017-05-03 09:25:57 · 1293 阅读 · 0 评论 -
Gym - 101350G (容斥原理)
G. Snake Rana time limit per test4.0 s memory limit per test256 MB inputstandard input outputstandard output Old Macdonald wants to build a new hen house for his hens. He buys a new rectangular ar原创 2017-08-01 09:44:24 · 781 阅读 · 0 评论 -
hdu 1695 GCD(容斥原理)
GCDTime Limit: 6000/3000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others) Total Submission(s): 12106 Accepted Submission(s): 4576Problem Description Given 5 integers: a, b, c, d, k, y原创 2017-08-08 11:02:45 · 237 阅读 · 0 评论 -
hdu 5668 中国剩余定理(模版)
CircleTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/65536 K (Java/Others) Total Submission(s): 565 Accepted Submission(s): 190Problem Description Satiya August is in charge of原创 2017-08-07 19:41:06 · 352 阅读 · 0 评论 -
hdu 5728 (公式推导+指数循环节)
PowModTime Limit: 3000/1500 MS (Java/Others) Memory Limit: 262144/262144 K (Java/Others) Total Submission(s): 1221 Accepted Submission(s): 428Problem Description Declare: k=∑(m,i=1)φ(i∗n) mod原创 2017-08-04 18:49:49 · 510 阅读 · 0 评论 -
(多校) hdu 6035 Colorful Tree
Colorful TreeTime Limit: 6000/3000 MS (Java/Others) Memory Limit: 131072/131072 K (Java/Others) Total Submission(s): 1741 Accepted Submission(s): 722Problem Description There is a tree with n n原创 2017-07-28 15:46:04 · 287 阅读 · 0 评论 -
POJ 3243 Clever Y BSGS 算法 (模板)
Clever Y Time Limit: 5000MS Memory Limit: 65536K Total Submissions: 8920 Accepted: 2222 DescriptionLittle Y finds there is a very interesting formula in mathematics:XY mod Z = KGiven X, Y,原创 2017-08-13 19:11:47 · 298 阅读 · 0 评论 -
hdu 3292 佩尔方程一系列操作
No more tricks, Mr NanguoTime Limit: 3000/1000 MS (Java/Others) Memory Limit: 65535/32768 K (Java/Others) Total Submission(s): 445 Accepted Submission(s): 294Problem Description Now Sailormoon原创 2017-08-15 11:00:22 · 285 阅读 · 0 评论 -
(多校)hdu 6050 Funny Function
Funny FunctionTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others) Total Submission(s): 142 Accepted Submission(s): 53Problem Description Function Fx,ysatisfies原创 2017-07-27 19:27:05 · 1466 阅读 · 8 评论 -
高斯消元模板
高斯消元模板原创 2017-02-08 23:05:29 · 210 阅读 · 0 评论 -
CCPC/ACM(杭州)热身赛
There are some positive integer numbers, and you want to divide them into two nonempty sets (every integer should be in and only in one set) and get a value descripted below:Assume that set AA has n1n1原创 2016-10-18 20:44:05 · 783 阅读 · 0 评论 -
hdu 5895 Mathematician QSC(快速幂+指数循环节)
Mathematician QSCTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 131072/131072 K (Java/Others)Total Submission(s): 326 Accepted Submission(s): 172Problem DescriptionQSC drea原创 2016-09-21 16:50:23 · 448 阅读 · 0 评论 -
Codeforces 697A - Pineapple Incident
A. Pineapple Incidenttime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputTed has a pineapple. This pineapple is原创 2016-07-15 10:51:56 · 695 阅读 · 0 评论 -
Codeforces Round #363 (Div. 2) C. Vacations(逻辑运算)
C. Vacationstime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputVasya has n days of vacations! So he decided to原创 2016-07-20 11:55:25 · 718 阅读 · 1 评论 -
Codeforces 702D - Road to Post Office
D. Road to Post Officetime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputVasiliy has a car and he wants to get原创 2016-07-31 09:11:40 · 530 阅读 · 0 评论 -
hdu 4549 M斐波那契数列
M斐波那契数列Time Limit: 3000/1000 MS (Java/Others) Memory Limit: 65535/32768 K (Java/Others)Total Submission(s): 2833 Accepted Submission(s): 849Problem DescriptionM斐波那契数列F[n]是一种整数数列,原创 2016-08-05 20:55:14 · 288 阅读 · 0 评论 -
RSA加密原理
首先先解决这样一个问题,b和m已知求满足下面条件的x, xk≡b(modm)xk≡b(modm)x^k\equiv b\pmod m 这个问题若是没有限制条件的话会变得很棘手,那么假设条件变得更强让gcd(b,m)=1;便会想到利用欧拉函数求出ϕ(m)ϕ(m)\phi(m),之后解下面的不定方程。xkxkx k - yyy...原创 2016-08-17 20:57:39 · 536 阅读 · 0 评论 -
Codeforces 711E ZS and The Birthday Paradox
E. ZS and The Birthday Paradoxtime limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputZS the Coder has recently fo原创 2016-09-11 00:11:37 · 411 阅读 · 0 评论 -
Codeforces Round #368 (Div. 2) C. Pythagorean Triples
C. Pythagorean Triples time limit per test1 second memory limit per test256 megabytes inputstandard input outputstandard output Katya studies in a fifth grade. Recently her class studied right tri原创 2016-08-31 17:49:03 · 302 阅读 · 0 评论 -
UVALive 7327 Digit Division
We are given a sequence of n decimal digits. The sequence needs to be partitioned into one or morecontiguous subsequences such that each subsequence, when interpreted as a decimal number, is divisib原创 2016-08-10 19:46:27 · 821 阅读 · 0 评论 -
POJ 1845 Sumdiv(数论+快速幂)
SumdivTime Limit: 1000MS Memory Limit: 30000KTotal Submissions: 19576 Accepted: 4930DescriptionConsider two natural numbers A and B. Let S be the sum of all natur原创 2016-09-19 23:48:44 · 447 阅读 · 0 评论 -
BZOJ 1002:[FJOI2007] 轮状病毒 (基尔霍夫矩阵生成树定理)
轮状病毒有很多变种,所有轮状病毒的变种都是从一个轮状基产生的。一个N轮状基由圆环上N个不同的基原子 和圆心处一个核原子构成的,2个原子之间的边表示这2个原子之间的信息通道。如下图所示 N轮状病毒的产生规律是在一个N轮状基中删去若干条边,使得各原子之间有唯一的信息通道,例如共有16个不 同的3轮状病毒,如下图所示 现给定n(N<=100),编程计算有多少个不同的n轮状...原创 2018-02-08 09:56:31 · 296 阅读 · 0 评论