自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(23)
  • 收藏
  • 关注

转载 sicily 1176 Two Ends

Description In the two-player game "Two Ends", an even number of cards is laid out in a row. On each card, face up, is written a positive integer. Players take turns removing a card from either ...

2013-01-30 20:49:00 132

转载 sicily 1563 GECKO

Description During the rainy season, one of the walls in the house is infested with mosquitoes. The wall is covered by h × w square tiles, where there are h rows of tiles from top to bottom, a...

2013-01-25 16:06:00 135

转载 sicily 1083 Networking

Description You are assigned to design network connections between certain points in a wide area. You are given a set of points in the area, and a set of possible routes for the cables that may ...

2013-01-25 16:05:00 173

转载 sicily 1211 商人的宣传

Description Bruce是K国的商人,他在A州成立了自己的公司,这次他的公司生产出了一批性能很好的产品,准备宣传活动开始后的第L天到达B州进行新品拍卖,期间Bruce打算将产品拿到各个州去做推销宣传,以增加其影响力。 K国有很多个州,每个州都与其他一些州相邻,但是K国对商人作宣传却有一些很奇怪的规定:1、商人只能从某些州到达另外一些州,即连通路线是单向的,而且有些州...

2013-01-25 16:03:00 102

转载 sicily 1781 Knight

Description Your task is to write a program to calculate the minimum number of moves needed for a knight to reach one point from another. The possible knight moves are shown in Figure 1. Figure...

2013-01-25 16:02:00 79

转载 sicily 1935 二叉树重建

Description 对于二叉树T,可以递归定义它的先序遍历、中序遍历和后序遍历如下: PreOrder(T)=T的根节点+PreOrder(T的左子树)+PreOrder(T的右子树) InOrder(T)=InOrder(T的左子树)+T的根节点+InOrder(T的右子树) PostOrder(T)=PostOrder(T的左子树)+PostOrder(T的右子树)+T的根...

2013-01-25 16:01:00 117

转载 sicily 1090 Highways

Description The island nation of Flatopia is perfectly flat. Unfortunately, Flatopia has no public highways. So the traffic is difficult in Flatopia. The Flatopian government is aware of this pr...

2013-01-25 16:00:00 99

转载 sicily 1050 Numbers & Letters

Description In the early 80’s, a popular TV show on Dutch television was ‘Cijfers en Letters’ (Numbers and Letters). This game consisted of two game elements, in which the main goal was to outcl...

2013-01-25 15:58:00 79

转载 sicily 1317 Sudoku

Description Sudoku is a placement puzzle. The goal is to enter a symbol in each cell of a grid, most frequently a9x9grid made up of3x3subgrids. Each row, column and subgrid must contain...

2013-01-25 15:57:00 207

转载 sicily 1135 飞越原野

Description 勇敢的德鲁伊法里奥出色的完成了任务之后,正在迅速的向自己的基地撤退。但由于后面有着一大群追兵,所以法里奥要尽快地返回基地,否则就会被敌人捉住。 终于,法里奥来到了最后的一站:泰拉希尔原野,穿过这里就可以回到基地了。然而,敌人依然紧追不舍。不过,泰拉希尔的地理条件对法里奥十分有利,众多的湖泊随处分布。敌人需要绕道而行,但法里奥拥有变成鹰的特殊能力,使得他能轻...

2013-01-25 15:56:00 219

转载 sicily 1210 二叉树

Description 在众多的数据结构中,二叉树是一种特殊而重要的结构,有着广泛的应用。二叉树或者是一个结点,或者有且仅有一个结点为二叉树的根,其余结点被分成两个互不相交的子集,一个作为左子集,另一个作为右子集,每个子集又是一个二叉树。 遍历一棵二叉树就是按某条搜索路径巡访其中每个结点,使得每个结点均被访问一次,而且仅被访问一次。最常使用的有三种遍历的方式: 1.前序遍历:若...

2013-01-25 15:54:00 75

转载 sicily 1444 Prime Path

Description The ministers of the cabinet were quite upset by the message from the Chief of Security stating that they would all have to change the four-digit room numbers on their offices.— It ...

2013-01-25 15:53:00 109

转载 sicily 1215 脱离地牢

Description 在一个神秘的国度里,年轻的王子Paris与美丽的公主Helen在一起过着幸福的生活。他们都随身带有一块带磁性的阴阳魔法石,身居地狱的魔王Satan早就想得到这两块石头了,只要把它们熔化,Satan就能吸收其精华大增自己的魔力。于是有一天他趁二人不留意,把他们带到了自己的地牢,分别困在了不同的地方。然后Satan念起了咒语,准备炼狱,界时二人都将葬身于这地牢里...

2013-01-25 15:52:00 186

转载 sicily 1048 Inverso

Description The game of ‘Inverso’ is played on a 3x3 grid of colored fields (each field is either black or white). Each field is numbered as follows:1 2 34 5 67 8 9The player can c...

2013-01-25 15:49:00 351

转载 sicily 1034 Forest

Description In the field of computer science, forest is important and deeply researched , it is a model for many data structures . Now it’s your job here to calculate the depth and width of gi...

2013-01-25 15:48:00 121

转载 sicily 1011 Lenny's Lucky Lotto

Description Lenny likes to play the game of lotto. In the lotto game, he picks a list ofNunique numbers in the range from1toM. If his list matches the list of numbers that are drawn, he w...

2013-01-25 15:47:00 82

转载 sicily 1004 I Conduit!

Description Irv Kenneth Diggit works for a company that excavates trenches, digs holes and generally tears up people's yards. Irv's job is to make sure that no underground pipe or cable is under...

2013-01-25 15:46:00 153

转载 sicily 1002 Anti-prime Sequences

Description Given a sequence of consecutive integers n,n+1,n+2,...,m, an anti-prime sequence is a rearrangement of these integers so that each adjacent pair of integers sums to a composite (no...

2013-01-25 15:45:00 109

转载 sicily 1031 Campus

Description At present, Zhongshan University has 4 campuses with a total area of 6.17 square kilometers sitting respectively on both sides of the Pearl River or facing the South China Sea. The...

2013-01-25 15:43:00 110

转载 sicily 1024 Magic Island

Description There are N cities and N-1 roads in Magic-Island. You can go from one city to any other. One road only connects two cities. One day, The king of magic-island want to visit the island...

2013-01-25 15:42:00 100

转载 sicily 1150 简单魔板 sicily 1151 魔板 sicily 1515 魔板C

这三道题目大体相同,只是数据处理方式不同,需要修改的地方很少,因此只以1150为例说明即可。 Description 魔板由8个大小相同方块组成,分别用涂上不同颜色,用1到8的数字表示。 其初始状态是 1 2 3 4 8 7 6 5 对魔板可进行三种基本操作: A操作(上下行互换): 8 7 6 5 1 2 3 4 B操作(每次以行循环右移一个): 4 1 2 ...

2013-01-25 15:41:00 128

转载 sicily 1152 简单的马周游问题 and sicily 1153 马的周游问题

1152: Description 在一个5 * 6的棋盘中的某个位置有一只马,如果它走29步正好经过除起点外的其他位置各一次,这样一种走法则称马的周游路线,试设计一个算法,从给定的起点出发,找出它的一条周游路线。 为了便于表示一个棋盘,我们按照从上到下,从左到右对棋盘的方格编号,如下所示: 123456 78...

2013-01-25 15:39:00 106

转载 sicily 2502 买珍珠

Description 珍珠市场上有N(N≤ 100)种等级的珍珠,每种珍珠的需求数量是Bi,单位价格是Pi。 不幸的是,这个市场是黑市——购买一种珍珠,需要额外多付10个同种珍珠的钱(如果不购买当然不用)。 针对这种情况,我们可以用高等级的珍珠来代替低等级的珍珠。 举个例子, 需要5个等级1的珠子(单位价格10元)、100个等级2的珠子(单位价格20元)。按照正...

2013-01-25 15:37:00 65

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除