随笔分类 -  ACM-数论

摘要:查找第k大Submit Page Summary Time Limit: 1 Sec Memory Limit: 128 Mb Submitted: 316 Solved: 20 Description小W有很强的好胜心,也有... 阅读全文
posted @ 2018-07-07 22:46 StarHai 阅读(418) 评论(0) 推荐(0)
摘要:DescriptionOpen-pit mining is a surface mining technique of extracting rock or minerals from the earth by their removal from an open p... 阅读全文
posted @ 2018-05-27 22:14 StarHai 阅读(435) 评论(0) 推荐(0)
摘要:Description車是中国象棋中的一种棋子,它能攻击同一行或同一列中没有其他棋子阻隔的棋子。一天,小度在棋盘上摆起了许多車……他想知道,在一共N×M个点的矩形棋盘中摆最多个数的車使其互不攻击的方案数。他经过思考,得出了答案。但他仍不满足,想增加一个条件:对于任何一... 阅读全文
posted @ 2018-05-24 22:18 StarHai 阅读(270) 评论(0) 推荐(0)
摘要:欧拉函数: 定义和简单性质 欧拉函数在OI中是个非常重要的东西,不知道的话会吃大亏的. 欧拉函数用希腊字母φ表示,φ(N)表示N的欧拉函数. 对φ(N)的值,我们可以通俗地理解为小于N且与N互质的数的个数(包含1). 欧拉函数的一些性质: 1.对于素数p, φ(p)=p-1,对于对两个素数p,q φ 阅读全文
posted @ 2018-04-06 14:57 StarHai 阅读(371) 评论(0) 推荐(0)
摘要:欧拉函数: 定义和简单性质 欧拉函数在OI中是个非常重要的东西,不知道的话会吃大亏的. 欧拉函数用希腊字母φ表示,φ(N)表示N的欧拉函数. 对φ(N)的值,我们可以通俗地理解为小于N且与N互质的数的个数(包含1). 欧拉函数的一些性质: 1.对于素数p, φ(p)=p-1,对于对两个素数p,q φ 阅读全文
posted @ 2018-04-06 14:57 StarHai 阅读(334) 评论(0) 推荐(0)
摘要:DescriptionEverybody loves big numbers (if you do not, you might want to stop reading at this point). There are many ways of construct... 阅读全文
posted @ 2018-04-06 14:43 StarHai 阅读(254) 评论(0) 推荐(0)
摘要:The season for Snuke Festival has come again this year. First of all, Ringo will perform a ritual to summon Snuke. For the ritual, he ... 阅读全文
posted @ 2018-03-04 22:45 StarHai 阅读(270) 评论(0) 推荐(0)
摘要:We have a 3×3 grid. A number ci,j is written in the square (i,j), where (i,j) denotes the square at the i-th row from the top and the ... 阅读全文
posted @ 2018-03-04 22:41 StarHai 阅读(280) 评论(0) 推荐(0)
摘要:Find the maximum possible sum of the digits (in base 10) of a positive integer not greater than N.Constraints1≤N≤1016N is an integer.I... 阅读全文
posted @ 2018-03-04 22:35 StarHai 阅读(246) 评论(0) 推荐(0)
摘要:An adult game master and N children are playing a game on an ice rink. The game consists of K rounds. In the i-th round, the game mast... 阅读全文
posted @ 2018-03-04 22:24 StarHai 阅读(256) 评论(0) 推荐(0)