- 博客(31)
- 收藏
- 关注
原创 POJ 1797 Heavy Transportation
Heavy TransportationTime Limit: 3000MS Memory Limit: 30000KTotal Submissions: 17984 Accepted: 4744DescriptionBackground Hugo Heavy is happy. After the breakdown
2013-08-24 13:31:27 1121
原创 POJ 1125 Stockbroker Grapevine
Stockbroker GrapevineTime Limit: 1000MS Memory Limit: 10000KTotal Submissions: 23783 Accepted: 13067DescriptionStockbrokers are known to overreact to rumours. You
2013-08-23 13:53:56 768
原创 POJ 3723 Conscription
ConscriptionTime Limit: 1000MS Memory Limit: 65536KTotal Submissions: 6325 Accepted: 2184DescriptionWindy has a country, and he wants to build an army to protect
2013-08-23 13:43:55 913
原创 POJ 2349 Arctic Network
题意:也是求最小生成树,不过在n个点当中可以有s个点已经相连。用krusical做。记录每次加的边数,当连通的边数有n-s便跳出。#include#include#include#include#includeusing namespace std;int n,s,f[1010];struct node{ int x,y; double s;}e[
2013-08-23 13:33:40 835
原创 POJ 2377 Bad Cowtractors
这是先前做的几道最小生成树的题目,基本都是裸题。题意:求最大生成树由于数据比较水,用prime和krusical都可以。我是用krusical做的#include#include#include#include#includeusing namespace std;int n,m,f[1010];struct node{ int x,y,s;}e[20010]
2013-08-23 13:29:54 1015
原创 POJ 2031 Building a Space Station
Building a Space StationTime Limit: 1000MS Memory Limit: 30000KTotal Submissions: 3705 Accepted: 1884DescriptionYou are a member of the space station engineering
2013-08-17 18:05:34 939
原创 POJ 1861 Network
NetworkTime Limit: 1000MS Memory Limit: 30000KTotal Submissions: 12067 Accepted: 4652 Special JudgeDescriptionAndrew is working as system administrator and is
2013-08-17 18:01:24 901
原创 POJ 1679 The Unique MST (次小生成树)
The Unique MSTTime Limit: 1000MS Memory Limit: 10000KTotal Submissions: 17785 Accepted: 6176DescriptionGiven a connected undirected graph, tell if its minimum spa
2013-08-17 17:57:49 1184 2
原创 POJ 水题若干
POJ 3176 Cow Bowling链接: http://poj.org/problem?id=3176这道题可以算是dp入门吧。可以用一个二维数组从下向上来搜索从而得到最大值。优化之后可以直接用一维数组来存。(PS 用一维的时候要好好想想具体应该怎么存,还是有技巧的)#include#include#include#includeusing namespace std
2013-08-17 17:51:26 952
原创 POJ 1287 Networking
NetworkingTime Limit: 1000MS Memory Limit: 10000KTotal Submissions: 5417 Accepted: 2915DescriptionYou are assigned to design network connections between certain p
2013-08-14 13:20:26 892
原创 POJ 1251 Jungle Roads
Jungle RoadsTime Limit: 1000MS Memory Limit: 10000KTotal Submissions: 17586 Accepted: 7937DescriptionThe Head Elder of the tropical island of Lagrishan has a
2013-08-14 13:08:53 935
原创 POJ 水题若干
POJ 1013 Counterfeit Dollar链接: http://poj.org/problem?id=1013题意:有一打硬币,其中有一个是假币,质量可能较轻,也可能较重。通过三次称重将假币找出。由于计算机很难模仿人的想法来实现问题。这道题我纠结了很久。最后我是通过一一枚举的笨方法做的。就是从A硬币开始到L硬币结束,一一假设其为假币,其中又分为轻和重。当符合三次称重
2013-08-14 11:16:28 837
原创 每日一水 POJ8道水题
1. POJ 3299 Humidex链接: http://poj.org/problem?id=3299这道题是已知H,D,T三者的运算关系,然后告诉你其中两个。求另一个。#include#include#include#includeusing namespace std;int main (){ char c,h; double T,D,H;
2013-08-12 11:59:27 1005
原创 532 - Dungeon Master
Dungeon Master You are trapped in a 3D dungeon and need to find the quickest way out! The dungeon is composed of unit cubes which may or may not be filled with rock. It takes one minute to
2013-08-12 10:52:28 967
原创 784 - Maze Exploration
Maze Exploration A maze of rectangular rooms is represented on a two dimensional grid as illustrated in figure 1a. Each point of the grid is represented by a character. The points of room walls ar
2013-08-12 10:48:33 1012
原创 657 - The die is cast
The die is cast InterGames is a high-tech startup company that specializes in developing technology that allows users to play games over the Internet. A market analysis has alerted them to the fac
2013-08-07 22:59:41 926
原创 839 - Not so Mobile
Not so Mobile Before being an ubiquous communications gadget, a mobile was just a structure made of strings and wires suspending colourfull things. This kind of mobile is usually found hanging ove
2013-08-07 22:47:36 1242
原创 327 - Evaluating Simple C Expressions
Evaluating Simple C Expressions The task in this problem is to evaluate a sequence of simple C expressions, buy you need not know C to solve the problem! Each of the expressions will appear on a l
2013-08-07 22:39:20 1024
原创 699 - The Falling Leaves
The Falling Leaves Each year, fall in the North Central region is accompanied by the brilliant colors of the leaves on the trees, followed quickly by the falling leaves accumulating under the tree
2013-08-07 22:16:38 984
原创 712 - S-Trees
S-Trees A Strange Tree (S-tree) over the variable set is a binary tree representing a Boolean function . Each path of the S-tree begins at the root node and consists of n+1 nodes. Each of the
2013-08-07 21:52:33 1210
原创 297 - Quadtrees (UVa)
Quadtrees A quadtree is a representation format used to encode images. The fundamental idea behind the quadtree is that any image can be split into four quadrants. Each quadrant may again be split
2013-08-04 18:08:08 1205
原创 548 - Tree (UVa OJ)
Tree You are to determine the value of the leaf node in a given binary tree that is the terminal node of a path of least value from the root of the binary tree to any leaf. The value of a path is
2013-08-04 14:01:38 1162
原创 112 - Tree Summing
Tree Summing BackgroundLISP was one of the earliest high-level programming languages and, with FORTRAN, is one of the oldest languages currently being used. Lists, which are the fundamental da
2013-08-03 21:35:36 1026
原创 10050 - Hartals
Problem D: Hartals A social research organization has determined a simple set of parameters to simulate the behavior of the political parties of our country. One of the parameters is a positive in
2013-08-03 21:19:23 812
原创 540 - Team Queue
Team Queue Queues and Priority Queues are data structures which are known to most computer scientists. The Team Queue, however, is not so well known, though it occurs often in everyday life. At lu
2013-08-03 21:13:44 1210
原创 11111 - Generalized Matrioshkas
Problem B - Generalized Matrioshkas Vladimir worked for years making matrioshkas, those nesting dolls that certainly represent truly Russian craft. A matrioshka is a doll that may be opened in two
2013-08-01 13:36:21 1118
原创 442 - Matrix Chain Multiplication
Matrix Chain Multiplication Suppose you have to evaluate an expression like A*B*C*D*E where A,B,C,D and E are matrices. Since matrix multiplication is associative, the order in which multiplicatio
2013-08-01 13:26:11 1062
原创 673 - Parentheses Balance
Parentheses Balance You are given a string consisting of parentheses () and []. A string of this type is said to be correct:(a)if it is the empty string(b)if A and B are correct, AB is correct,(
2013-08-01 13:16:23 1198
原创 10152 - ShellSort
Problem D: ShellSortHe made each turtle stand on another one's backAnd he piled them all up in a nine-turtle stack.And then Yertle climbed up. He sat down on the pile.What a wonderful view! He
2013-08-01 13:03:39 870
原创 133 - The Dole Queue
The Dole Queue In a serious attempt to downsize (reduce) the dole queue, The New National Green Labour Rhinoceros Party has decided on the following strategy. Every day all dole applicants will be
2013-08-01 12:53:52 1068
原创 101 - The Blocks Problem
The Blocks Problem Background Many areas of Computer Science use simple, abstract domains for both analytical and empirical studies. For example, an early AI study of planning and robotics (
2013-08-01 11:42:15 993
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人