上一页 1 ··· 13 14 15 16 17 18 19 20 21 ··· 34 下一页
摘要: 题目:输入两个大整数,用数组保存每一位数,然后用分治法计算; 思路:输入X Y,X高位用A数组保存,低位用B数组保存,Y高位用C数组保存,低位用D数组保存,则:X=A*10^(n/2)+B Y=C*10^(n/2)+D 分治方法:X*Y=A*C*10^n+((A-B)*(D-C)+A*C+B*D)* 阅读全文
posted @ 2016-09-16 11:15 茶飘香~ 阅读(7922) 评论(16) 推荐(0) 编辑
摘要: 在博客中写公式的两种方法(链接)因为要在博客中写公式,所以参考了别人两种方法,如下: 1,在博客设置中,html头中添加代码,导入mathML库如: <script type="text/javascript" src="http://common.cnblogs.com/script/ASCIIM 阅读全文
posted @ 2016-09-14 14:37 茶飘香~ 阅读(182) 评论(0) 推荐(0) 编辑
摘要: 题目链接 http://www.lydsy.com/JudgeOnline/problem.php?id=2038 Description 作为一个生活散漫的人,小Z每天早上都要耗费很久从一堆五颜六色的袜子中找出一双来穿。终于有一天,小Z再也无法忍受这恼人的找袜子过程,于是他决定听天由命……具体来说 阅读全文
posted @ 2016-09-14 13:46 茶飘香~ 阅读(236) 评论(0) 推荐(0) 编辑
摘要: 题目:排列问题,设R={r1,r2...rn}是要进行排列的n个元素,求R的全排列perm(R); a、递归关系 Ri=R-{ri} perm(R)=U(ri)perm(Ri) b、终止条件:n=1时 c、参数 int k,int m 代码如下: 运行结果如下: 阅读全文
posted @ 2016-09-13 21:15 茶飘香~ 阅读(373) 评论(0) 推荐(0) 编辑
摘要: 题目链接 http://acm.split.hdu.edu.cn/showproblem.php?pid=5869 Problem Description This is a simple problem. The teacher gives Bob a list of problems about 阅读全文
posted @ 2016-09-13 10:43 茶飘香~ 阅读(274) 评论(0) 推荐(0) 编辑
摘要: 题目链接 http://acm.split.hdu.edu.cn/showproblem.php?pid=5875 Problem Description The shorter, the simpler. With this problem, you should be convinced of 阅读全文
posted @ 2016-09-11 21:32 茶飘香~ 阅读(238) 评论(0) 推荐(0) 编辑
摘要: 题目链接 https://icpcarchive.ecs.baylor.edu/index.php?option=com_onlinejudge&Itemid=8&page=show_problem&problem=2988 problem Description Flatland governme 阅读全文
posted @ 2016-09-11 15:26 茶飘香~ 阅读(411) 评论(0) 推荐(0) 编辑
摘要: 题目链接 http://acm.split.hdu.edu.cn/showproblem.php?pid=4745 题意:两只兔子,在n块围成一个环形的石头上跳跃,每块石头有一个权值ai,一只从左往右跳,一只从右往左跳,每跳一次,两只兔子所在的石头的权值都要相等,在一圈内(各自不能超过各自的起点,也 阅读全文
posted @ 2016-09-10 21:52 茶飘香~ 阅读(392) 评论(0) 推荐(0) 编辑
摘要: 题目链接 http://acm.split.hdu.edu.cn/showproblem.php?pid=4283 Problem Description The TV shows such as You Are the One has been very popular. In order to 阅读全文
posted @ 2016-09-10 19:59 茶飘香~ 阅读(644) 评论(0) 推荐(0) 编辑
摘要: 题目链接 http://acm.split.hdu.edu.cn/showproblem.php?pid=5877 Problem Description You are given a rooted tree of N nodes, labeled from 1 to N. To the ith 阅读全文
posted @ 2016-09-10 19:11 茶飘香~ 阅读(481) 评论(0) 推荐(0) 编辑
上一页 1 ··· 13 14 15 16 17 18 19 20 21 ··· 34 下一页