FDNY to the Rescue!Time Limit: 1000MS Memory Limit: 10000KTotal Submissions: 2213 Accepted: 664DescriptionThe Fire Department of New York (FDNY) has always been proud of their response time to fires in New York City, but they want to make their
MultipleTime Limit: 1000MS Memory Limit: 32768KTotal Submissions: 5625 Accepted: 1217Descriptiona program that, given a natural number N between 0 and 4999 (inclusively), and M distinct decimal digits X1,X2..XM (at least one), finds the smallest
ArbitrageTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 3277 Accepted Submission(s): 1489Problem DescriptionArbitrage is the use of discrepancies in currency exchange rates to transform one
QueryTime Limit: 20000/10000 MS (Java/Others) Memory Limit: 65536/65536 K (Java/Others)Total Submission(s): 2063 Accepted Submission(s): 707Problem DescriptionYou are given two strings s1[0..l1], s2[0..l2] and Q - number of queries.Your task
The DoorsTime Limit: 1000MS Memory Limit: 10000KTotal Submissions: 5360 Accepted: 2173DescriptionYou are to find the length of the shortest path through a chamber containing obstructing walls. The chamber will always have sides at x = 0, x = 10, y =
Problem DescriptionThe counter-terrorists found a time bomb in the dust. But this time the terrorists improve on the time bomb. The number sequence of the time bomb counts from 1 to N. If the current number sequence includes the sub-sequence "49",
DescriptionGiven two integers a and b, we write the numbers between a and b, inclusive, in a list. Your task is to calculate the number of occurrences of each digit. For example, if a = 1024 and b = 1032, the list will be1024 1025 1026 1027 1028 1029
DescriptionA Benedict monk No.16 writes down the decimal representations of all natural numbers between and includingm and n, m ≤ n. How many 0's will he write down?InputInput consists of a sequence of lines. Each line contains two unsigned 32-bit
GraphTime Limit: 10000/5000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 695 Accepted Submission(s): 113Problem DescriptionP. T. Tigris is a student currently studying graph theory. One day, when he was
http://codeforces.com/contest/337/problem/AThe end of the school year is near and Ms. Manana, the teacher, will soon have to say goodbye to a yet another class. She decided to prepare a goodbye present for hern students and give each of them a
http://codeforces.com/contest/337/problem/BManao has a monitor. The screen of the monitor has horizontal to vertical length ratioa:b. Now he is going to watch a movie. The movie's frame has horizontal to vertical length ratioc:d. Manao adjusts the
Problem DescriptionA wqb-number, or B-number for short, is a non-negative integer whose decimal form contains the sub- string "13" and can be divided by 13. For example, 130 and 2613 are wqb-numbers, but 143 and 2639 are not. Your task is to
Maze StretchingTime Limit: 1000MS Memory Limit: 65536KTotal Submissions: 711 Accepted: 190DescriptionUsually the path in a maze is calculated as the sum of steps taken from the starting point until the ending point, assuming that the distance of one
題目大意:有n個學生,p門課程,一個學生可以選修多門課程,現在要為這p門課程分別選一個課代表,且一個學生只能當一個科目的課代表,問是否能滿足所有課程都找到課代表。運用常用模板:#include <iostream>using namespace std;const int N = 310;int map[N][N], flag[N];int pre[N];int n, m, num;int find(int cur){ int i ; for(i = 1; i <=
The RobberyTime Limit: 5000MS Memory Limit: 65536KTotal Submissions: 1517 Accepted: 134DescriptionIn the downtown of Bucharest there is a very big bank with a very big vault. Inside the vault there are N very big boxes numbered from 1 to N. Inside
打星號的表示個人認為比較經典,或是演算法,構圖比較好的題目1062* 昂貴的聘禮 枚舉等級限制+dijkstra1087* A Plug for UNIX 2分匹配1094 Sorting It All Out floyd 或 拓撲1112* Team Them Up! 2分圖染色+DP1125 Stockbroker Grapevine FLOYD1135 Domino Effect 最短路1149* PIGS 網路流1161* Walls floyd1201 Intervals 差分約束12
Domino EffectTime Limit: 1000MS Memory Limit: 65536KTotal Submissions: 7164 Accepted: 1813DescriptionDid you know that you can use domino bones for other things besides playing Dominoes? Take a number of dominoes and build a row by standing them on