
ACM
spring-again
这个作者很懒,什么都没留下…
展开
-
小孩报数问题(poj 3750)
Description有N个小孩围成一圈,给他们从1开始依次编号,现指定从第W个开始报数,报到第S个时,该小孩出列,然后从下一个小孩开始报数,仍是报到S个出列,如此重复下去,直到所有的小孩都出列(总人数不足S个时将循环报数),求小孩出列的顺序。Input第一行输入小孩的人数N(N接下来每行输入一个小孩的名字(人名不超过15个字符) 最后一行输入W,S (W Outp原创 2013-08-02 18:56:56 · 953 阅读 · 0 评论 -
ACM Rank Table(poj 2397)
DescriptionACM contests, like the one you are participating in, are hosted by the special software. That software, among other functions, preforms a job of accepting and evaluating teams' solution原创 2013-08-12 22:07:08 · 1138 阅读 · 0 评论 -
Printer Queue(poj 3125)
DescriptionThe only printer in the computer science students' union is experiencing an extremely heavy workload. Sometimes there are a hundred jobs in the printer queue and you may have to wait fo原创 2013-08-08 11:22:22 · 653 阅读 · 0 评论 -
Team Queue(poj 2259)
DescriptionQueues 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-07 22:12:13 · 805 阅读 · 0 评论 -
A Stack or A Queue?(zoj 3210)
Do you know stack and queue? They're both important data structures. A stack is a "first in last out" (FILO) data structure and a queue is a "first in first out" (FIFO) one.Here comes the problem: g原创 2013-08-05 17:20:00 · 1087 阅读 · 0 评论 -
Adding Reversed Numbers(zoj 2001)
The Antique Comedians of Malidinesia prefer comedies to tragedies. Unfortunately, most of the ancient plays are tragedies. Therefore the dramatic advisor of ACM has decided to transfigure some trage原创 2013-07-27 11:09:40 · 819 阅读 · 1 评论 -
Polynomial Showdown(zoj 1720)
Given the coefficients of a polynomial from degree 8 down to 0, you are to format the polynomial in a readable format with unnecessary characters removed. For instance, given the coefficients 0, 0,原创 2013-07-28 17:00:02 · 909 阅读 · 0 评论 -
Error Correction(zoj 1949)
DescriptionA boolean matrix has the parity property when each row and each column has an even sum, i.e. contains an even number of bits which are set. Here's a 4 x 4 matrix which has the parity pr原创 2013-07-31 16:33:28 · 595 阅读 · 0 评论 -
rails(zoj1259)
There is a famous railway station in PopPush City. Country there is incredibly hilly. The station was built in last century. Unfortunately, funds were extremely limited that time. It was possible to原创 2013-08-04 18:05:03 · 781 阅读 · 0 评论 -
Nearest Common Ancestors
DescriptionA rooted tree is a well-known data structure in computer science and engineering. An example is shown below: In the figure, each node is labeled with an integer from {1, 2,...,16原创 2013-08-29 10:06:49 · 567 阅读 · 0 评论