随笔分类 -  数学 基础

摘要:D. My pretty girl Noora In Pavlopolis University where Noora studies it was decided to hold beauty contest "Miss Pavlopolis University". Let's describ 阅读全文
posted @ 2017-07-07 20:26 meekyan 阅读(267) 评论(0) 推荐(0)
摘要:2-3 Trees Problem Description 2-3 tree is an elegant data structure invented by John Hopcroft. It is designed to implement the same functionality as t 阅读全文
posted @ 2017-03-13 20:59 meekyan 阅读(204) 评论(0) 推荐(1)
摘要:1803: 2016 Description 给出正整数 n 和 m,统计满足以下条件的正整数对 (a,b) 的数量: 1. 1≤a≤n,1≤b≤m; 2. a×b 是 2016 的倍数。 给出正整数 n 和 m,统计满足以下条件的正整数对 (a,b) 的数量: 1. 1≤a≤n,1≤b≤m; 2. 阅读全文
posted @ 2016-09-04 12:25 meekyan 阅读(573) 评论(0) 推荐(0)
摘要:Lucky Problem Description WLD is always very lucky.His secret is a lucky number K.k is a fixed odd number. Now he meets a stranger with N numbers:a1,a 阅读全文
posted @ 2016-07-29 11:38 meekyan 阅读(426) 评论(0) 推荐(0)
摘要:C16H:Magical Balls C16H:Magical Balls 总时间限制: 1000ms 内存限制: 262144kB描述 Wenwen has a magical ball. When put on an infinite plane, it will keep duplicatin 阅读全文
posted @ 2016-07-18 21:11 meekyan 阅读(327) 评论(0) 推荐(0)
摘要:4517: [Sdoi2016]排列计数 Description 求有多少种长度为 n 的序列 A,满足以下条件: 1 ~ n 这 n 个数在序列中各出现了一次 若第 i 个数 A[i] 的值为 i,则称 i 是稳定的。序列恰好有 m 个数是稳定的 满足条件的序列可能很多,序列数对 10^9+7 取 阅读全文
posted @ 2016-04-29 22:54 meekyan 阅读(468) 评论(0) 推荐(0)
摘要:C. Little Artem and Random Variable Little Artyom decided to study probability theory. He found a book with a lot of nice exercises and now wants you 阅读全文
posted @ 2016-04-28 16:23 meekyan 阅读(235) 评论(0) 推荐(0)
摘要:1005: [HNOI2008]明明的烦恼 Description 自从明明学了树的结构,就对奇怪的树产生了兴趣......给出标号为1到N的点,以及某些点最终的度数,允许在任意两点间连线,可产生多少棵度数满足要求的树? 自从明明学了树的结构,就对奇怪的树产生了兴趣......给出标号为1到N的点, 阅读全文
posted @ 2016-04-28 15:24 meekyan 阅读(699) 评论(0) 推荐(2)
摘要:高斯消元法,是线性代数中的一个算法,可用来求解线性方程组,并可以求出矩阵的秩,以及求出可逆方阵的逆矩阵。高斯消元法的原理是:若用初等行变换将增广矩阵 化为 ,则AX = B与CX = D是同解方程组。所以我们可以用初等行变换把增广矩阵转换为行阶梯阵,然后回代求出方程的解。 以上是线性代数课的回顾,下 阅读全文
posted @ 2016-04-24 13:58 meekyan 阅读(282) 评论(0) 推荐(0)
摘要:Magical GCD The Magical GCD of a nonempty sequence of positive integers is defined as the product of its lengthand the greatest common divisor of all i 阅读全文
posted @ 2016-04-03 13:55 meekyan 阅读(475) 评论(0) 推荐(0)
摘要:Given the value of a+b and ab you will have to find the value of an + bnInputThe input file contains several lines of inputs. Each line except the last ... 阅读全文
posted @ 2016-01-24 21:33 meekyan 阅读(280) 评论(0) 推荐(0)
摘要:Prime BasesProblem DescriptionGiven any integer base b >= 2, it is well known that every positive integer n can be uniquely represented in base b. Tha... 阅读全文
posted @ 2016-01-22 23:26 meekyan 阅读(281) 评论(0) 推荐(0)
摘要:Close Enough ComputationsProblem DescriptionThe nutritional food label has become ubiquitous. A sample label is shown to the right. On the label the n... 阅读全文
posted @ 2016-01-22 17:18 meekyan 阅读(215) 评论(0) 推荐(0)
摘要:B. Word CutLet's consider one interesting word game. In this game you should transform one word into another through special operations.Let's say we h... 阅读全文
posted @ 2016-01-21 14:50 meekyan 阅读(454) 评论(0) 推荐(0)
摘要:Rock-Paper-ScissorsNikephoros and Polycarpus play rock-paper-scissors. The loser gets pinched (not too severely!).Let us remind you the rules of this ... 阅读全文
posted @ 2016-01-21 00:12 meekyan 阅读(299) 评论(0) 推荐(1)
摘要:Silly SortYour younger brother has an assignment and needs some help. His teacher gave him a sequence ofnumbers to be sorted in asc... 阅读全文
posted @ 2016-01-19 21:32 meekyan 阅读(513) 评论(0) 推荐(0)
摘要:PolygonJohn has been given a segment of lenght N, however he needs a polygon. In order to create a polygonhe has cut given segment K... 阅读全文
posted @ 2016-01-19 18:05 meekyan 阅读(198) 评论(0) 推荐(0)
摘要:Consider rectangular coordinate system and point L(X, Y ) which is randomly chosen among all pointsin the area A which is defined in the following mann... 阅读全文
posted @ 2016-01-14 22:31 meekyan 阅读(372) 评论(0) 推荐(0)
摘要:You live in a village but work in another village. You decided to follow the straight path between yourhouse (A) and the working place (B), but there ... 阅读全文
posted @ 2016-01-14 13:46 meekyan 阅读(253) 评论(0) 推荐(0)
摘要:DescriptionFedya studies in a gymnasium. Fedya's maths hometask is to calculate the following expression:(1n + 2n + 3n + 4n)mod5for given value ofn. F... 阅读全文
posted @ 2016-01-12 15:12 meekyan 阅读(529) 评论(0) 推荐(0)