![](https://img-blog.csdnimg.cn/20201014180756928.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
ACM
文章平均质量分 87
iambabao
这个作者很懒,什么都没留下…
展开
-
Codeforces Round#458Div.1+2 C.Travelling Salesman and Special Numbers 数位dp
C. Travelling Salesman and Special Numberstime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputThe Travelling Salesman spends a lot of time travelling s...原创 2018-02-08 14:49:35 · 350 阅读 · 0 评论 -
POJ1012-Joseph 约瑟夫环问题
JosephTime Limit: 1000MS Memory Limit: 10000KTotal Submissions: 56986 Accepted: 21688DescriptionThe Joseph's problem is notoriously known. For those who are not familiar with the original problem: fro...原创 2018-04-07 22:56:23 · 912 阅读 · 1 评论 -
模板:欧几里得 扩展欧几里得 乘法逆元
一、欧几里得算法 求a,b的最小公约数。int GCD(int a, int b) { int r; while (b) { r = a % b; a = b; b = r; } return a;}二、扩展欧几里得 求解方程ax + by = gcd(a, b),并返回gcd(a,b)。 简单证明://求解ax + by = gcd...原创 2018-03-26 15:29:54 · 334 阅读 · 0 评论 -
模板:中国剩余定理
一、m[]两两互质时 简单证明: 必要时数据类型改为long long#include <iostream>#include <sstream>#include <iomanip>#include <string>#include <numeric>#include <vector>#i...原创 2018-03-26 22:04:38 · 154 阅读 · 0 评论 -
POJ1007-DNA Sorting
DNA SortingTime Limit: 1000MS Memory Limit: 10000KTotal Submissions: 106816 Accepted: 42795DescriptionOne measure of ``unsortedness'' in a sequence is the number of pairs of entries that are out of or...原创 2018-03-26 22:37:07 · 132 阅读 · 0 评论 -
POJ1008-Maya Calendar
Maya CalendarTime Limit: 1000MS Memory Limit: 10000KTotal Submissions: 81342 Accepted: 25016DescriptionDuring his last sabbatical, professor M. A. Ya made a surprising discovery about the old Maya cal...原创 2018-03-26 23:42:11 · 155 阅读 · 0 评论 -
POJ1013-Counterfeit Dollar
Counterfeit DollarTime Limit: 1000MS Memory Limit: 10000KTotal Submissions: 50542 Accepted: 15817DescriptionSally Jones has a dozen Voyageur silver dollars. However, only eleven of the coins are true ...原创 2018-04-21 19:49:05 · 155 阅读 · 0 评论 -
POJ1014-Dividing 多重背包+二进制划分
DividingTime Limit: 1000MS Memory Limit: 10000KTotal Submissions: 74312 Accepted: 19441DescriptionMarsha and Bill own a collection of marbles. They want to split the collection among themselves so tha...原创 2018-04-21 20:34:14 · 316 阅读 · 0 评论 -
POJ1016-Numbers That Count
Numbers That CountTime Limit: 1000MS Memory Limit: 10000KTotal Submissions: 21528 Accepted: 7227Description"Kronecker's Knumbers" is a little company that manufactures plastic digits for use in signs ...原创 2018-04-25 21:31:04 · 351 阅读 · 0 评论 -
POJ1017-Packets
PacketsTime Limit: 1000MS Memory Limit: 10000KTotal Submissions: 60023 Accepted: 20357DescriptionA factory produces products packed in square packets of the same height h and of the sizes 1*1, 2*2, 3*...原创 2018-04-25 22:30:31 · 117 阅读 · 0 评论 -
POJ2387-Til the Cows Come Home Dijkstra
Til the Cows Come HomeTime Limit: 1000MS Memory Limit: 65536KTotal Submissions: 68691 Accepted: 23025DescriptionBessie is out in the field and wants to get back to the barn to get as much sleep as pos...原创 2018-05-23 20:46:50 · 175 阅读 · 0 评论 -
POJ2253-Frogger Floyd
FroggerTime Limit: 1000MS Memory Limit: 65536KTotal Submissions: 56007 Accepted: 17619DescriptionFreddy Frog is sitting on a stone in the middle of a lake. Suddenly he notices Fiona Frog who is sittin...原创 2018-05-23 21:37:36 · 186 阅读 · 0 评论 -
POJ1011-Sticks 搜索
SticksTime Limit: 1000MS Memory Limit: 10000KTotal Submissions: 151709 Accepted: 36124DescriptionGeorge took sticks of the same length and cut them randomly until all parts became at most 50 units lon...原创 2018-04-07 22:15:01 · 199 阅读 · 0 评论 -
POJ1010-STAMPS 搜索
STAMPSTime Limit: 1000MS Memory Limit: 10000KTotal Submissions: 19490 Accepted: 5712DescriptionHave you done any Philately lately? You have been hired by the Ruritanian Postal Service (RPS) to design ...原创 2018-04-07 20:52:20 · 461 阅读 · 0 评论 -
HDU5726-GCD 区间GCD+二分
GCDTime Limit: 10000/5000 MS (Java/Others) Memory Limit: 65536/65536 K (Java/Others)Total Submission(s): 4611 Accepted Submission(s): 1655Problem DescriptionGive you a sequence of N(N≤100,000) i...原创 2018-02-08 16:41:17 · 250 阅读 · 0 评论 -
模板:区间GCD
一、RMQ实现 RMQ不能实现更新。#include <iostream>#include <sstream>#include <iomanip>#include <string>#include <numeric>#include <vector>#include <queue>#in原创 2018-02-09 16:21:14 · 536 阅读 · 0 评论 -
Codeforces Round#458Div.1+2 D.Bash and a Tough Math Puzzle 区间GCD
D. Bash and a Tough Math Puzzletime limit per test2.5 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputBash likes playing with arrays. He has an array a1, a2, ... an of...原创 2018-02-09 15:50:26 · 277 阅读 · 0 评论 -
Codeforces Round#460 Div.2 D.Substring 搜索
D. Substringtime limit per test3 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputYou are given a graph with n nodes and m directed edges. One lowercase letter is assig...原创 2018-02-07 22:20:16 · 272 阅读 · 0 评论 -
Codeforces Round#459 Div.2 D.MADMAX 搜索+记忆化DP
D. MADMAXtime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputAs we all know, Max is the best video game player among her friends. Her friends were so j...原创 2018-02-07 22:20:49 · 186 阅读 · 0 评论 -
POJ1000-A+B Problem
A+B ProblemTime Limit: 1000MS Memory Limit: 10000KTotal Submissions: 446656 Accepted: 251482DescriptionCalculate a+bInputTwo integer a,b (0<=a,b<=10)OutputOutput a+bSample Input1 2Sample Output3...原创 2018-03-23 19:46:41 · 168 阅读 · 0 评论 -
POJ1002-487-3279 map应用
487-3279Time Limit: 2000MS Memory Limit: 65536KTotal Submissions: 303418 Accepted: 54259DescriptionBusinesses like to have memorable telephone numbers. One way to make a telephone number memorable is ...原创 2018-03-23 20:26:46 · 208 阅读 · 0 评论 -
POJ1003-Hangover
HangoverTime Limit: 1000MS Memory Limit: 10000KTotal Submissions: 132971 Accepted: 64680DescriptionHow far can you make a stack of cards overhang a table? If you have one card, you can create a maximu...原创 2018-03-23 20:55:58 · 115 阅读 · 0 评论 -
POJ1004-Financial Management
Financial ManagementTime Limit: 1000MS Memory Limit: 10000KTotal Submissions: 193201 Accepted: 73428DescriptionLarry graduated this year and finally has a job. He's making a lot of money, but somehow ...原创 2018-03-23 21:04:55 · 196 阅读 · 0 评论 -
POJ1005-I Think I Need a Houseboat
I Think I Need a HouseboatTime Limit: 1000MS Memory Limit: 10000KTotal Submissions: 108947 Accepted: 47310DescriptionFred Mapper is considering purchasing some land in Louisiana to build his house on....原创 2018-03-23 21:25:57 · 136 阅读 · 0 评论 -
POJ1006-Biorhythms 中国剩余定理
BiorhythmsTime Limit: 1000MS Memory Limit: 10000KTotal Submissions: 143074 Accepted: 46000DescriptionSome people believe that there are three cycles in a person's life that start the day he or she is ...原创 2018-03-23 22:09:31 · 183 阅读 · 0 评论 -
POJ1797 Heavy Transportation Dijkstra
Heavy TransportationTime Limit: 3000MS Memory Limit: 30000KTotal Submissions: 44998 Accepted: 11768DescriptionBackground Hugo Heavy is happy. After the breakdown of the Cargolifter project he can now ...原创 2018-05-23 23:36:16 · 168 阅读 · 0 评论