上一页 1 ··· 30 31 32 33 34 35 36 37 38 ··· 68 下一页
摘要: The Euler function Problem Description The Euler function phi is an important kind of function in number theory, (n) represents the amount of the numb 阅读全文
posted @ 2016-12-29 18:02 勿忘初心0924 阅读(289) 评论(0) 推荐(0) 编辑
摘要: GCD Again Problem Description Do you have spent some time to think and try to solve those unsolved problem after one ACM contest? No? Oh, you must do 阅读全文
posted @ 2016-12-29 15:57 勿忘初心0924 阅读(275) 评论(0) 推荐(0) 编辑
摘要: 欧拉函数证明 欧拉函数定义:定义一个数n,φ(n)为不大于n的,与n互质的数的个数。 证明方法用到容斥定理:容斥定理的原理如图: A∪B∪C=A+B+C - A∩B - B∩C - A∩C + A∩B∩C; 欧拉函数证明: 小于等于n的基数有n个,讨论所有n的素因子,只要是素因子的倍数的是都不是n的 阅读全文
posted @ 2016-12-29 15:25 勿忘初心0924 阅读(5079) 评论(0) 推荐(0) 编辑
摘要: Assignments Problem Description In a factory, there are N workers to finish two types of tasks (A and B). Each type has N tasks. Each task of type A n 阅读全文
posted @ 2016-12-29 12:17 勿忘初心0924 阅读(372) 评论(0) 推荐(0) 编辑
摘要: Wall Problem Description Once upon a time there was a greedy King who ordered his chief Architect to build a wall around the King's castle. The King w 阅读全文
posted @ 2016-12-28 21:46 勿忘初心0924 阅读(398) 评论(0) 推荐(0) 编辑
摘要: Maple trees Problem Description There are a lot of trees in HDU. Kiki want to surround all the trees with the minimal required length of the rope . As 阅读全文
posted @ 2016-12-28 20:24 勿忘初心0924 阅读(624) 评论(0) 推荐(0) 编辑
摘要: WisKey的眼神 Problem Description WisKey的眼镜有500多度,所以眼神不大好,而且他有个习惯,就是走路喜欢看着地(不是为了拣钱哦^_^),所以大家下次碰见他的时候最好主动打下招呼,呵呵.但是Rabbit总是喜欢扮神秘,一天WisKey去食堂排队等着买饭,突然收到一道短消 阅读全文
posted @ 2016-12-26 22:05 勿忘初心0924 阅读(277) 评论(0) 推荐(0) 编辑
摘要: Surround the Trees Problem Description There are a lot of trees in an area. A peasant wants to buy a rope to surround all these trees. So at first he 阅读全文
posted @ 2016-12-26 17:43 勿忘初心0924 阅读(531) 评论(0) 推荐(0) 编辑
摘要: 了解凸包及Graham扫描法 问题描述:二位平面内,给定n个散乱的点,求一个最小凸多边形(凸包),使得n个点都不在凸多边形外。 问题的解决用到Graham算法: 算法步骤: 1.取y坐标最小的一点,作为p0,显然p0一定在凸包上。 2.将p0作为坐标系原点,其他点按极角从小到大排序,从p1开始编号。 阅读全文
posted @ 2016-12-26 17:42 勿忘初心0924 阅读(6392) 评论(0) 推荐(4) 编辑
摘要: 多边形求重心总结 多边形求重心: 逆时针给出你n边形的n个顶点,求重心利用的原理就是,加权平均,如下图: 将a点作为所有小三角形的公共顶点,那么多边形abcdef的中心=); 三角形的面积:用向量的×乘就可以 s1=向量ac×向量ba;(尽量不要用海伦公式,因为海林公式除法太多,容易卡精度) 三角形 阅读全文
posted @ 2016-12-25 14:45 勿忘初心0924 阅读(6787) 评论(0) 推荐(1) 编辑
上一页 1 ··· 30 31 32 33 34 35 36 37 38 ··· 68 下一页