07 2017 档案

摘要:Number TransformationIn this problem, you are given an integer number s. You can transform any integer number A to another integer num... 阅读全文
posted @ 2017-07-31 17:38 岩扉 阅读(346) 评论(0) 推荐(0)
摘要:Birthday Paradox Sometimes some mathematical results are hard to believe. One of the common problems is the birthday paradox. Suppose ... 阅读全文
posted @ 2017-07-31 10:42 岩扉 阅读(231) 评论(0) 推荐(0)
摘要:Poj1142 Smith NumbersSmith Numbers Time Limit: 1000MS Memory Limit: 10000K Total Submissions: 13854 Accepted: 4716 Descr... 阅读全文
posted @ 2017-07-30 21:58 岩扉 阅读(218) 评论(0) 推荐(0)
摘要:容斥模板代码,int solve(){ int ans = 0; //是那四个数的倍数的数的数量 for (int i = 1 ; i < (1<<4) ; i++) //选数 { int ant = 0; //选中数的数量 int k = 1; /... 阅读全文
posted @ 2017-07-30 21:01 岩扉 阅读(233) 评论(0) 推荐(0)
摘要:Halloween treatsEvery year there is the same problem at Halloween: Each neighbour is only willing to give a certain total number of sw... 阅读全文
posted @ 2017-07-30 14:17 岩扉 阅读(182) 评论(0) 推荐(0)
摘要:Find a multiple The input contains N natural (i.e. positive integer) numbers ( N int a[10010],sum[10010];int main(){ int n; whil... 阅读全文
posted @ 2017-07-30 11:24 岩扉 阅读(206) 评论(0) 推荐(0)
摘要:Patrick and Shopping今天 Patrick 等待着他的朋友 Spongebob来他家玩。为了迎接 Spongebob,Patrick 需要去他家附近的两家商店 买一些吃的。他家离第一家商店有d1米远,离第二家商店有d2米远。还有,两家商店之间的距离... 阅读全文
posted @ 2017-07-30 09:23 岩扉 阅读(276) 评论(0) 推荐(0)
摘要:In this problem you are to calculate the sum of all integers from 1 to n, but you should take all powers of two with minus in the sum.... 阅读全文
posted @ 2017-07-30 09:15 岩扉 阅读(246) 评论(0) 推荐(0)
摘要:Bear and Three Balls Limak is a little polar bear. He has n balls, thei-th ball has size ti.Limak wants to give one ball to each of h... 阅读全文
posted @ 2017-07-23 15:49 岩扉 阅读(225) 评论(0) 推荐(0)
摘要:Today, Wet Shark is given n bishops on a 1000 by 1000 grid. Both rows and columns of the grid are numbered from 1 to 1000. Rows are nu... 阅读全文
posted @ 2017-07-21 16:35 岩扉 阅读(324) 评论(0) 推荐(0)
摘要:1203: 杨八方的语文问题 [字符串] 时间限制: 1 Sec 内存限制: 128 MB 题目描述 转眼间一学期就将要过去了,杨八方也在大学里经历了许多事情,最难忘的自然是学校里的各色课程。杨八方很喜欢中国的古典文化,所以当她知道大学有语文课的时候是很开心的。更幸运... 阅读全文
posted @ 2017-07-21 08:43 岩扉 阅读(178) 评论(0) 推荐(0)