- 博客(42)
- 资源 (2)
- 收藏
- 关注
原创 poj2453------An Easy Problem 进制转换 水题
An Easy ProblemTime Limit: 1000MS Memory Limit: 65536KTotal Submissions: 7161 Accepted: 4236DescriptionAs we known, data stored in the computers is in binary form.
2012-08-31 21:18:57 1152
原创 poj3270 Cow Sorting-------置换群
Cow SortingTime Limit: 2000MS Memory Limit: 65536KTotal Submissions: 4746 Accepted: 1730DescriptionFarmer John's N (1 ≤ N ≤ 10,000) cows are lined up to be milked
2012-08-31 19:15:58 3115
原创 poj2429 GCD & LCM Inverse 数论 大数分解以及找所有因子
GCD & LCM InverseTime Limit: 2000MS Memory Limit: 65536KTotal Submissions: 7146 Accepted: 1303DescriptionGiven two positive integers a and b, we can easily calculat
2012-08-30 21:37:43 1575
原创 poj3696 The Luckiest number 数论好题
The Luckiest numberTime Limit: 1000MS Memory Limit: 65536KTotal Submissions: 3536 Accepted: 917DescriptionChinese people think of '8' as the lucky digit. Bob al
2012-08-30 19:09:14 2451
原创 hdu2177 取(2堆)石子游戏----威佐夫博弈,输出第一步最优策略
取(2堆)石子游戏Time Limit: 3000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 427 Accepted Submission(s): 258Problem Description有两堆石子,数量任意,可以不同。游戏开始由两
2012-08-29 19:52:02 2065
原创 hdu3951 Coin Game---博弈 对称性
Coin GameTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 747 Accepted Submission(s): 454Problem DescriptionAfter hh has learned h
2012-08-29 17:11:39 2115
原创 hdu3544 Alice's Game----博弈 贪心
Alice's GameTime Limit: 2000/2000 MS (Java/Others) Memory Limit: 65535/32768 K (Java/Others)Total Submission(s): 232 Accepted Submission(s): 95Problem DescriptionAlice and Bob have g
2012-08-29 15:11:10 2386
原创 hdu4259 Double Dealing----置换群
Double DealingTime Limit: 50000/20000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 290 Accepted Submission(s): 132Problem DescriptionTake a deck of
2012-08-25 20:52:24 1413
原创 hdu3389 Game-----博弈想法题 难
GameTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 133 Accepted Submission(s): 90Problem DescriptionBob and Alice are playing
2012-08-20 21:11:21 1681
原创 hdu3032 Nim or not Nim?-----sg打表找规律 允许把一堆石子分成两堆小的
Nim or not Nim?Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 406 Accepted Submission(s): 185Problem DescriptionNim is a two-pla
2012-08-20 18:48:48 2062
原创 hdu2897 邂逅明下------找规律 类似于巴什博奕
邂逅明下Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 968 Accepted Submission(s): 458Problem Description当日遇到月,于是有了明。当我遇到了你,便成了侣。那
2012-08-20 16:27:15 3941
原创 hdu2516 取石子游戏-----找规律 必败点---斐波那契数列
取石子游戏Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 1394 Accepted Submission(s): 780Problem Description1堆石子有n个,两人轮流取.先取者第1次可以取任意
2012-08-20 10:10:00 1763
原创 hdu1525-------Euclid's Game 找规律
Euclid's GameTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 893 Accepted Submission(s): 419Problem DescriptionTwo players, Stan
2012-08-20 08:57:17 1446
转载 hdu1404 Digital Deletions------SG
Digital DeletionsTime Limit: 4000/2000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 1238 Accepted Submission(s): 449Problem DescriptionDigital delet
2012-08-18 16:37:36 1428
原创 hdu2149 Public Sale-------巴什博奕 每次加一个数
Public SaleTime Limit: 1000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 1835 Accepted Submission(s): 1150Problem Description虽然不想,但是现实总归是现实,Lel
2012-08-18 13:03:33 1293
原创 hdu1851 A Simple Game-----sg
A Simple GameTime Limit: 1000/1000 MS (Java/Others) Memory Limit: 32768/65535 K (Java/Others)Total Submission(s): 674 Accepted Submission(s): 395Problem DescriptionAgrael likes play
2012-08-17 20:05:35 1274
原创 hdu4371 Alice and Bob---博弈------多校联合8
Alice and BobTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 99 Accepted Submission(s): 62Problem DescriptionAlice and Bob are
2012-08-16 20:00:46 1612
原创 poj1704 Georgia and Bob------P/N分析
Georgia and BobTime Limit: 1000MSMemory Limit: 10000KTotal Submissions: 5821Accepted: 1637DescriptionGeorgia and Bob decide to play a self-invented game. They draw
2012-08-16 10:25:34 2500
原创 POI2000 Stripes -------SG
Stripes Time Limit:1000MSMemory Limit:30000KBTotal Submit:71Accepted:31Description Stripes is a two player game. Necessary requisites are a board and rectangular stripes in three colours:
2012-08-16 09:24:25 1627
原创 poj1740 A New Stone Game----分析P/N 从剩下的石子中取任意颗放到别的堆
A New Stone GameTime Limit: 1000MS Memory Limit: 30000KTotal Submissions: 4111 Accepted: 2179DescriptionAlice and Bob decide to play a new stone game.At the beginni
2012-08-15 16:07:49 2064
转载 Sprague-Grundy函数-------------博弈
原载网址:http://www.cnblogs.com/Knuth/archive/2009/09/05/1561007.html上一期的文章里我们仔细研究了Nim游戏,并且了解了找出必胜策略的方法。但如果把Nim的规则略加改变,你还能很快找出必胜策略吗?比如说:有n堆石子,每次可以从第1堆石子里取1颗、2颗或3颗,可以从第2堆石子里取奇数颗,可以从第3堆及以后石子里取任意颗……这时看上去问题
2012-08-15 14:41:56 656
原创 hdu4365 Palindrome graph-------多校联合七
Palindrome graphTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 96 Accepted Submission(s): 38Problem DescriptionIn addition fon
2012-08-14 18:53:15 1254
原创 hdu1930 And Now, a Remainder from Our Sponsor-----中国剩余定理
And Now, a Remainder from Our SponsorTime Limit: 5000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 380 Accepted Submission(s): 153Problem Descrip
2012-08-13 10:39:04 1588
原创 poj1305 Fermat vs. Pythagoras----勾股数
Fermat vs. PythagorasTime Limit: 2000MS Memory Limit: 10000KTotal Submissions: 1026 Accepted: 593DescriptionComputer generated and assisted proofs and verification
2012-08-12 14:50:40 1237
原创 poj1091跳蚤---------容斥
跳蚤Time Limit: 1000MS Memory Limit: 10000KTotal Submissions: 6454 Accepted: 1805DescriptionZ城市居住着很多只跳蚤。在Z城市周六生活频道有一个娱乐节目。一只跳蚤将被请上一个高空钢丝的正中央。钢丝很长,可以看作是无限长。节目主持人会给该跳蚤发
2012-08-12 10:14:15 3964 1
原创 hdu3336 Count the string-------KMP
Count the stringTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 2104 Accepted Submission(s): 999Problem DescriptionIt is well known tha
2012-08-10 14:46:16 788
原创 poj1226 Substrings------KMP
SubstringsTime Limit: 1000MSMemory Limit: 10000KTotal Submissions: 9258Accepted: 3177DescriptionYou are given a number of case-sensitive strings of alphabetic chara
2012-08-10 14:37:28 842
原创 poj3080 Blue Jeans-------KMP
Blue Jeans Time Limit:1000MSMemory Limit:65536KTotal Submissions:8235Accepted:3447DescriptionThe Genographic Project is a research partnership
2012-08-10 14:25:26 4842 1
原创 hdu1841 Find the Shortest Common Superstring-----KMP
Find the Shortest Common SuperstringTime Limit: 1000/1000 MS (Java/Others) Memory Limit: 65535/65535 K (Java/Others)Total Submission(s): 971 Accepted Submission(s): 243Problem DescriptionT
2012-08-10 14:18:50 1335 2
原创 poj2752 Milking Grid--------KMP
Milking GridTime Limit:3000MSMemory Limit:65536KTotal Submissions:4024Accepted:1647DescriptionEvery morning when they are milked, the Farmer Joh
2012-08-10 13:49:59 1389
原创 poj2752 Seek the Name, Seek the Fame--------KMP
Seek the Name, Seek the FameTime Limit:2000MSMemory Limit:65536KTotal Submissions:8143Accepted:3822DescriptionThe little cat is so famous, that
2012-08-10 13:43:38 2583
原创 poj1961 Period----KMP
PeriodTime Limit:3000MSMemory Limit:30000KTotal Submissions:9694Accepted:4426DescriptionFor each prefix of a given string S with N characters (e
2012-08-10 13:35:31 844
原创 poj2406 Power Strings-------KMP
Power Strings Time Limit:3000MSMemory Limit:65536KTotal Submissions:23083Accepted:9679DescriptionGiven two strings a and b we define a*b to be
2012-08-10 13:29:40 4931 1
原创 hdu4350 Card-----多校联合六
水题。#include#include#includeusing namespace std;int num[53];int n,l,r;int mm;int ff[53];int tt[53];void count(){ while(1) { int cc=1; for(int i=l;i<=r;i++) tt[cc++]=ff[i];
2012-08-09 19:58:49 1430
原创 hdu4355 Party All the Time----------多校联合六 三分
因为是凸性的,可以在位置这个区间进行三分,比赛的时候用三分写这道题的时候我竟然在位置所对应的标号之间进行三分,脑残了。#include#include#include#include#includeusing namespace std;const double eps = 1e-12;struct Node{ double x; double w;}node
2012-08-09 18:58:21 1803
原创 hdu4345 Permutation-----多校联合五
这题首先是道数学题,用到了置换群的概念,其实是求相加和为N的最小公倍数的种类数,把数学思想抽象出来就成一道dp题了。 #include#include#include#define ll __int64using namespace std;const int N=1000;int prime[N]={0},num=1;int isprime[N]={1,1};ll dp[
2012-08-08 08:43:36 1259 4
原创 hdu4344 Mark the Rope-------多校联合五
这题比赛的时候思路基本上对了,除了当n就为一个素数的一次幂时候按我们的思路是S就是这个素数,事实上标程是1,但是按照题意He will choose a lengthL (N>L>1) and he defines the mark’s value equals L,不应该输出1。贴一下标程,作为以后大数分解素因子的模板。#include #include #include #inc
2012-08-07 20:40:18 1143 4
原创 hdu4349 Xiao Ming's Hope-----多校联合五
水题。#include#include#include#define ll __int64using namespace std;ll power(int a,int b){ ll res=1; while(b) { if(b&1) res*=a; a=a*a; b>>=1; } return
2012-08-07 20:13:02 1278
原创 hdu4342 History repeat itself-------多校联合五
水题就不多说什么了。#include#include#include#define ll __int64using namespace std;int main(){ int t; ll n; scanf("%d",&t); while(t--) { scanf("%I64d",&n); if(n==1)
2012-08-07 19:51:42 928
原创 hdu2837 Calculation a^b%p=a^(b%phi(p)+phi(p))%p
CalculationTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 873 Accepted Submission(s): 192Problem DescriptionAssume that f(0) =
2012-08-07 09:55:46 3015
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人