2015年8月18日
摘要: Description A subsequence of a given sequence is the given sequence with some elements (possible none) left out. Given a sequence X = < x1, x2, ..., x 阅读全文
posted @ 2015-08-18 10:41 xx-sisley 阅读(136) 评论(0) 推荐(0) 编辑
  2015年8月15日
摘要: Description The world financial crisis is quite a subject. Some people are more relaxed while others are quite anxious. John is one of them. He is ver 阅读全文
posted @ 2015-08-15 21:40 xx-sisley 阅读(133) 评论(0) 推荐(0) 编辑
摘要: Description 一组研究人员正在设计一项实验,以测试猴子的智商。他们将挂香蕉在建筑物的屋顶,同时,提供一些砖块给这些猴子。如果猴子足够聪明,它应当能够通过合理的放置一些砖块建立一个塔,并爬上去吃他们最喜欢的香蕉。 研究人员有n种类型的砖块,每种类型的砖块都有无限个。第i块砖块的长宽高分别用x 阅读全文
posted @ 2015-08-15 21:31 xx-sisley 阅读(163) 评论(0) 推荐(0) 编辑
摘要: Description Given a sequence a[1],a[2],a[3]......a[n], your job is to calculate the max sum of a sub-sequence. For example, given (6,-1,5,4,-7), the m 阅读全文
posted @ 2015-08-15 21:15 xx-sisley 阅读(191) 评论(0) 推荐(0) 编辑
  2015年8月8日
摘要: 题目描述: Once Bob took a paper stripe of n squares (the height of the stripe is 1 square). In each square he wrote an integer number, possibly negative. 阅读全文
posted @ 2015-08-08 19:44 xx-sisley 阅读(124) 评论(0) 推荐(0) 编辑
摘要: 题目描述如下: Vanya walks late at night along a straight street of length l, lit by n lanterns. Consider the coordinate system with the beginning of the str 阅读全文
posted @ 2015-08-08 19:10 xx-sisley 阅读(160) 评论(0) 推荐(0) 编辑
摘要: 题目: bobo has a sequence a 1,a 2,…,a n. He is allowed to swap two adjacent numbers for no more than k times. Find the minimum number of inversions afte 阅读全文
posted @ 2015-08-08 18:34 xx-sisley 阅读(185) 评论(0) 推荐(0) 编辑
摘要: 分配派问题题目大意: 我要过生日了,准备了n个不同半径大小的圆形的pie,我有f 个朋友要来参加我的聚会,我要将pie公平分配,且给每人(包括我自己)分配一块尽量大的pie。(因为碎块看起来不上台面。)求分配每个人的pie的体积的最大值。(pie的厚度一定,等于1) 分析: 运用二分法:将每个人能分 阅读全文
posted @ 2015-08-08 17:35 xx-sisley 阅读(219) 评论(0) 推荐(0) 编辑
  2015年8月6日
摘要: 题目大意: 有m本书,k个抄写员。m本书的页码分别为 p1,p2……pm……。他们同时开始抄写且工作效率相同。要求分配给抄写员们若干书,每个抄写员要抄写的书的顺序必须是连续相邻的。 请你分配书使他们在最少的时间里完成抄写任务。 分析: 使每个抄写员分配到的页数的最大值尽可能小。最大值的最小化问题加二 阅读全文
posted @ 2015-08-06 21:45 xx-sisley 阅读(147) 评论(0) 推荐(0) 编辑
  2015年8月5日
摘要: Description: In this problem, you have to analyze a particular sorting algorithm. The algorithm processes a sequence of n distinct integers by swappin 阅读全文
posted @ 2015-08-05 08:46 xx-sisley 阅读(137) 评论(0) 推荐(0) 编辑