Who's in the Middle Time Limit: 1000MS Memory Limit: 65536K Total Submissions: 34155 Accepted: 19875 Description FJ is surveying his herd to find the most average cow. He wants to know how much milk this 'median' cow gives: half of the cows give…
Robot Motion Time Limit: 1000MS Memory Limit: 10000K Total Submissions: 11262 Accepted: 5482 Description A robot has been programmed to follow the instructions in its path. Instructions for the next direction the robot is to move are laid down in a g…
Largest Rectangle in a Histogram Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others) Total Submission(s): 11706 Accepted Submission(s): 3219 Problem Description A histogram is a polygon composed of a sequence of rec…
#include<cstdio> #include<cstring> using namespace std; bool map[505][505]; int n, k; bool vis[505]; int linker[505]; void sscanf() { int x, y; scanf("%d%d",&n,&k); for(int i=1;i<=k;i++) { scanf("%d%d",&x,&am…
Description Give you three sequences of numbers A, B, C, then we give you a number X. Now you need to calculate if you can find the three numbers Ai, Bj, Ck, which satisfy the formula Ai+Bj+Ck = X. Input There are many cases. Every data case is descr…
Time Limit:3000MS Memory Limit:65536KB 64bit IO Format:%I64d & %I64u Submit Status Practice POJ 2406 Appoint description: Description Given two strings a and b we define a*b to be their concatenation. For example, if a = "abc" and b = "…
A Plug for UNIX Time Limit: 1000MS Memory Limit: 65536K Total Submissions: 14786 Accepted: 4994 Description You are in charge of setting up the press room for the inaugural meeting of the United Nations Internet eXecutive (UNIX), which has an interna…
Network Saboteur Time Limit: 2000MS Memory Limit: 65536K Total Submissions: 10147 Accepted: 4849 Description A university network is composed of N computers. System administrators gathered information on the traffic between nodes, and carefully divid…
4 Values whose Sum is 0 Time Limit: 15000MS Memory Limit: 228000K Total Submissions: 17875 Accepted: 5255 Case Time Limit: 5000MS Description The SUM problem can be formulated as follows: given four lists A, B, C, D of integer values, compute how man…
Gold Balanced Lineup Time Limit: 2000MS Memory Limit: 65536K Total Submissions: 13215 Accepted: 3873 Description Farmer John's N cows (1 ≤ N ≤ 100,000) share many similarities. In fact, FJ has been able to narrow down the list of features shared by h…
Snowflake Snow Snowflakes Time Limit: 4000MS Memory Limit: 65536K Total Submissions: 34762 Accepted: 9126 Description You may have heard that no two snowflakes are alike. Your task is to write a program to determine whether this is really true. Your…
Play on Words Time Limit: 1000MS Memory Limit: 10000K Total Submissions: 10620 Accepted: 3602 Description Some of the secret doors contain a very interesting word puzzle. The team of archaeologists has to solve it to open that doors. Because there is…
Labeling Balls Time Limit: 1000MS Memory Limit: 65536K Total Submissions: 11893 Accepted: 3408 Description Windy has N balls of distinct weights from 1 unit to N units. Now he tries to label them with 1 to N in such a way that: No two balls share the…
Ubiquitous Religions Time Limit: 5000MS Memory Limit: 65536K Total Submissions: 26678 Accepted: 13127 Description There are so many different religions in the world today that it is difficult to keep track of them all. You are interested in findi…
Radar Installation Time Limit: 1000MS Memory Limit: 10000K Total Submissions: 60120 Accepted: 13552 Description Assume the coasting is an infinite straight line. Land is in one side of coasting, sea in the other. Each small island is a point loca…
Doubles Time Limit: 1000MS Memory Limit: 10000K Total Submissions: 19954 Accepted: 11536 Description As part of an arithmetic competency program, your students will be given randomly generated lists of from 2 to 15 unique positive integers and as…
The 3n + 1 problem Time Limit: 1000MS Memory Limit: 10000K Total Submissions: 53927 Accepted: 17142 Description Problems in Computer Science are often classified as belonging to a certain class of problems (e.g., NP, Unsolvable, Recursive). In th…
Color Me Less Time Limit: 1000MS Memory Limit: 10000K Total Submissions: 31693 Accepted: 15424 Description A color reduction is a mapping from a set of discrete colors to a smaller one. The solution to this problem requires that you perform just…
Arctic Network Time Limit: 2000MS Memory Limit: 65536K Total Submissions: 9557 Accepted: 3187 Description The Department of National Defence (DND) wishes to connect several northern outposts by a wireless network. Two different communication tech…
False coin Time Limit: 1000MS Memory Limit: 65536K Total Submissions: 16418 Accepted: 4583 Description The "Gold Bar"bank received information from reliable sources that in their last group of N coins exactly one coin is false and differs in…
To the Max Time Limit: 1000MS Memory Limit: 10000K Total Submissions: 39058 Accepted: 20629 Description Given a two-dimensional array of positive and negative integers, a sub-rectangle is any contiguous sub-array of size 1*1 or greater located wi…
Parliament Time Limit: 1000MS Memory Limit: 10000K Total Submissions: 16521 Accepted: 6975 Description New convocation of The Fool Land's Parliament consists of N delegates. According to the present regulation delegates should be divided into dis…