摘要: DescriptionFreddy Frog is sitting on a stone in the middle of a lake. Suddenly he notices Fiona Frog who is sitting on another stone. He plans to visit her, but since the water is dirty and full of tourists' sunscreen, he wants to avoid swimming and instead reach her by jumping.Unfortunately Fio 阅读全文
posted @ 2013-03-16 20:15 Tamara.c 阅读(154) 评论(0) 推荐(0) 编辑
摘要: DescriptionWhile exploring his many farms, Farmer John has discovered a number of amazing wormholes. A wormhole is very peculiar because it is a one-way path that delivers you to its destination at a time that is BEFORE you entered the wormhole! Each of FJ's farms comprisesN(1 ≤N≤ 500) fields co 阅读全文
posted @ 2013-03-16 20:06 Tamara.c 阅读(207) 评论(0) 推荐(0) 编辑
摘要: DescriptionSeveral currency exchange points are working in our city. Let us suppose that each point specializes in two particular currencies and performs exchange operations only with these currencies. There can be several points specializing in the same pair of currencies. Each point has its own ex 阅读全文
posted @ 2013-03-16 19:58 Tamara.c 阅读(196) 评论(0) 推荐(0) 编辑
摘要: DescriptionThe cornfield maze is a popular Halloween treat. Visitors are shown the entrance and must wander through the maze facing zombies, chainsaw-wielding psychopaths, hippies, and other terrors on their quest to find the exit.One popular maze-walking strategy guarantees that the visitor will ev 阅读全文
posted @ 2013-03-16 19:50 Tamara.c 阅读(145) 评论(0) 推荐(0) 编辑
摘要: DescriptionFarmer John has been informed of the location of a fugitive cow and wants to catch her immediately. He starts at a pointN(0 ≤N≤ 100,000) on a number line and the cow is at a pointK(0 ≤K≤ 100,000) on the same number line. Farmer John has two modes of transportation: walking and teleporting 阅读全文
posted @ 2013-03-16 19:44 Tamara.c 阅读(140) 评论(0) 推荐(0) 编辑
摘要: DescriptionWFF 'N PROOF is a logic game played with dice. Each die has six faces representing some subset of the possible symbols K, A, N, C, E, p, q, r, s, t. A Well-formed formula (WFF) is any string of these symbols obeying the following rules:p, q, r, s, and t are WFFsifwis a WFF, Nwis a WFF 阅读全文
posted @ 2013-03-16 19:42 Tamara.c 阅读(153) 评论(0) 推荐(0) 编辑
摘要: DescriptionIn how many ways can you tile a 2xn rectangle by 2x1 or 2x2 tiles?Here is a sample tiling of a 2x17 rectangle.InputInput is a sequence of lines, each line containing an integer number 0 <= n <= 250.OutputFor each line of input, output one integer number in a separate line giving the 阅读全文
posted @ 2013-03-16 19:37 Tamara.c 阅读(328) 评论(0) 推荐(0) 编辑
摘要: DescriptionThere are so many different religions in the world today that it is difficult to keep track of them all. You are interested in finding out how many different religions students in your university believe in.You know that there are n students in your university (0 < n <= 50000). It i 阅读全文
posted @ 2013-03-16 19:32 Tamara.c 阅读(150) 评论(0) 推荐(0) 编辑
摘要: 题目跟2996一样的,就是把2996的结果和问题换了一下而已,做法思想不变。模拟题。。View Code 1 #include <stdio.h> 2 #include <string.h> 3 char ss[]= {"+---+---+---+---+---+---+---+---+"}; 4 char map[10][100]; 5 void init() 6 { 7 int i; 8 for(i=0; i<8; i++) 9 { 10 if(i&1) 11 strcpy(map[i],"|:::|...... 阅读全文
posted @ 2013-03-11 12:04 Tamara.c 阅读(132) 评论(0) 推荐(0) 编辑
摘要: DescriptionYour task is to read a picture of a chessboard position and print it in the chess notation.InputThe input consists of an ASCII-art picture of a chessboard with chess pieces on positions described by the input. The pieces of the white player are shown in upper-case letters, while the black 阅读全文
posted @ 2013-03-11 12:02 Tamara.c 阅读(132) 评论(0) 推荐(0) 编辑