摘要:
Ultra-QuickSorthttp://poj.org/problem?id=2299Time Limit: 7000MSMemory Limit: 65536KTotal Submissions: 30129Accepted: 10760DescriptionIn this problem, you have to analyze a particular sorting algorithm. The algorithm processes a sequence of n distinct integers by swapping two adjacent sequence elemen 阅读全文
posted @ 2013-01-03 22:20
Jack Ge
阅读(213)
评论(0)
推荐(0)
摘要:
Minimum Inversion Numberhttp://acm.hdu.edu.cn/showproblem.php?pid=1394Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others) Total Submission(s): 5566 Accepted Submission(s): 3411 Problem DescriptionThe inversion number of a given number sequence a1, a2, ..., an is the numb 阅读全文
posted @ 2013-01-03 20:15
Jack Ge
阅读(1329)
评论(0)
推荐(0)
摘要:
敌兵布阵http://acm.hdu.edu.cn/showproblem.php?pid=1166Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others) Total Submission(s): 22647 Accepted Submission(s): 9878 Problem DescriptionC国的死对头A国这段时间正在进行军事演习,所以C国间谍头子Derek和他手下Tidy又开始忙乎了。A国在海岸线沿直线布置了N个工兵营地,Derek和Tidy的任务就是要监视这些工兵营地的活 阅读全文
posted @ 2013-01-03 16:21
Jack Ge
阅读(186)
评论(0)
推荐(0)
摘要:
函数lower_bound()在first和last中的前闭后开区间进行二分查找,返回大于或等于val的第一个元素位置。如果所有元素都小于val,则返回last的位置举例如下:一个数组number序列为:4,10,11,30,69,70,96,100.设要插入数字3,9,111.pos为要插入的位置的下标则pos = lower_bound( number, number + 8, 3) - number,pos = 0.即number数组的下标为0的位置。pos = lower_bound( number, number + 8, 9) - number, pos = 1,即number数组 阅读全文
posted @ 2013-01-03 14:24
Jack Ge
阅读(562)
评论(0)
推荐(0)
摘要:
Leftmost Digithttp://acm.hdu.edu.cn/game/entry/problem/show.php?chapterid=2§ionid=1&problemid=11Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 1524 Accepted Submission(s): 689Problem DescriptionGiven a positive integer N, you should o 阅读全文
posted @ 2013-01-03 12:26
Jack Ge
阅读(2273)
评论(0)
推荐(0)
摘要:
找新朋友http://acm.hdu.edu.cn/game/entry/problem/show.php?chapterid=2§ionid=1&problemid=8Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 1560 Accepted Submission(s): 781Problem Description新年快到了,“猪头帮协会”准备搞一个聚会,已经知道现有会员N人,把会员从1到N编号,其中会长的号码是N 阅读全文
posted @ 2013-01-03 12:16
Jack Ge
阅读(1993)
评论(0)
推荐(0)
摘要:
Largest prime factorhttp://acm.hdu.edu.cn/game/entry/problem/show.php?chapterid=2§ionid=1&problemid=5Time Limit: 5000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 2728 Accepted Submission(s): 860Problem DescriptionEverybody knows any number can be c 阅读全文
posted @ 2013-01-03 11:10
Jack Ge
阅读(940)
评论(0)
推荐(0)

浙公网安备 33010602011771号