摘要: 2303: [Apio2011]方格染色Time Limit: 20 Sec Memory Limit: 256 MBSubmit: 2309 Solved: 879[Submit][Status][Discuss]DescriptionSam和他的妹妹Sara有... 阅读全文
posted @ 2018-10-19 10:55 The-Pines-of-Star 阅读(227) 评论(0) 推荐(0) 编辑
摘要: 一、ll qpow(ll a,ll b,ll p){ ll ret=1;a%=p; while(b) { if(b&1) ret=ret*a%p; b/=2;a=a*a%p; } return ret;}二、Lucasll lucas(ll n,ll m,ll p... 阅读全文
posted @ 2018-10-02 21:38 The-Pines-of-Star 阅读(157) 评论(0) 推荐(0) 编辑
摘要: #include#include#include#include#include#include#include#include#include#include#include#define ll long long#define lson l,m,rt>=1;a=a... 阅读全文
posted @ 2018-10-01 10:04 The-Pines-of-Star 阅读(97) 评论(0) 推荐(0) 编辑
摘要: 1.数据的全局与局部问题(打错变量)正确:错误:2.字符串处理时的清空问题(北京网络赛)a[i][j]=s[j],strlen(a[i][j]);就会把之前的长度都算进去3.强制类型转换(北京网络赛)int n;scanf("%lld",n);这个东西可能会出错4.矩... 阅读全文
posted @ 2018-09-22 23:40 The-Pines-of-Star 阅读(152) 评论(0) 推荐(0) 编辑
摘要: In a world where ordinary people cannot reach, a boy named "Koutarou" and a girl named "Sena" are playing a video game. The game syste... 阅读全文
posted @ 2018-09-10 19:15 The-Pines-of-Star 阅读(205) 评论(0) 推荐(0) 编辑
摘要: After Incident, a feast is usually held in Hakurei Shrine. This time Reimu asked Kokoro to deliver a Nogaku show during the feast. To ... 阅读全文
posted @ 2018-09-10 18:55 The-Pines-of-Star 阅读(186) 评论(0) 推荐(0) 编辑
摘要: There's a beach in the first quadrant. And from time to time, there are sea waves. A wave ( xx , yy ) means the wave is a rectangle wh... 阅读全文
posted @ 2018-09-10 18:34 The-Pines-of-Star 阅读(175) 评论(0) 推荐(0) 编辑
摘要: 题目链接题目大意:给你一个数n,你要将它分成若干数字的和,使其的lcm最大,并且对p取模思路:有一个很显然的性质:分成的若干个数字的必定互质。之后就是完全背包问题了。F[I]表示和为I的得到的最大lcm,F[I]=max(F[I-prime[j]*k]*k*prime... 阅读全文
posted @ 2018-09-05 23:11 The-Pines-of-Star 阅读(283) 评论(0) 推荐(0) 编辑
摘要: MexTime Limit: 15000/5000 MS (Java/Others) Memory Limit: 65535/65535 K (Java/Others)... 阅读全文
posted @ 2018-09-04 13:47 The-Pines-of-Star 阅读(252) 评论(0) 推荐(0) 编辑
摘要: 3.连分数表示法题目:1.hdu2281思路:原式化为:m^2-48x^2=1,(m=4n+3),得到最小正整数解:m1=7,x1=1 n[i] = 7 * n[i - 1] + 48 * x[i - 1]; x[i] = n[... 阅读全文
posted @ 2018-08-26 23:59 The-Pines-of-Star 阅读(132) 评论(0) 推荐(0) 编辑