摘要:
排序是一种很频繁的计算任务。现在考虑最多只有三值的排序问题。一个实际的例子是,当我们给某项竞赛的优胜者按金银铜牌序的时候。 在这个任务中可能的值只有三种1,2和3。我们用交换的方法把他排成升序的。 写一个程序计算出,给定的一个1,2,3组成的数字序列,排成升序所需的... 阅读全文
posted @ 2018-04-01 13:11
~~zcy
阅读(241)
评论(0)
推荐(0)
摘要:
DescriptionRobot Doc is located in the hall, with n computers stand in a line, numbered from left to right from 1 to n. Each computer... 阅读全文
posted @ 2018-04-01 11:02
~~zcy
阅读(128)
评论(0)
推荐(0)
摘要:
DescriptionCity X consists of n vertical and n horizontal infinite roads, forming n × n intersections. Roads (both vertical and horizo... 阅读全文
posted @ 2018-04-01 10:05
~~zcy
阅读(172)
评论(0)
推荐(0)

浙公网安备 33010602011771号