Submit | All submissions | Best solutions | Back to list |
QUALITY - Contest System Quality Assurance Tester |
Write a program to score a small, three-problem programming contest. Each input line contains
six space-separated integers representing raw score data. The first three integers are in the range
0 . . . 100000. They represent seconds taken to solve the first, second, and third problems, respec-
tively. Zero seconds indicates that a problem has not been solved. The last three integers are in
the range 0 . . . 100, representing the attempts taken to solve the first, second, and third problems,
respectively. Every failed attempt is penalized with 20 minutes, but only for problems that are
eventually solved.
Each output line should begin with the string team, followed by a single space, the input line
number, a colon, a single space, the number of solved problems, a comma, a single space, and the
total number of seconds including penalties it took for the solved problems.
Input: 0 777 0 4 1 1 1 1 1 1 1 1 Output: team 1: 1, 777 team 2: 3, 3
Added by: | Daniel Gómez Didier |
Date: | 2008-11-18 |
Time limit: | 1.710s |
Source limit: | 50000B |
Memory limit: | 1536MB |
Cluster: | Cube (Intel G860) |
Languages: | All except: ERL JS-RHINO NODEJS PERL6 VB.NET |
Resource: | 2007 U.Nacional - Circuito de Maratones ACIS / REDIS |
hide comments
|
||||||
2015-07-15 06:41:55
you have to add penalities but not subtract them. costed me 3 wa :( |
||||||
2015-06-13 16:27:29 Harshit
silly mistakes :( |
||||||
2013-12-30 23:33:05 Samil Vargas
i dont use EOF cause sometimes return Compilation Error i recommend to use while(cin >> varible != '\0') |
||||||
2012-06-20 17:24:15 marwan akkad
too easy I got AC for the first submission |
||||||
2012-06-12 08:30:37 xxx
Some more test cases: INPUT -> 0 0 1 1 1 1 1 1 1 4 3 2 10 0 20 1 8 1 OUTPUT-> team 1: 1, 1 team 2: 3 , 7203 team 3: 2 , 30 |
||||||
2012-06-11 07:09:37 dev2
please i need more test cases can anyone help me out .... |
||||||
2012-06-01 12:31:48 Ranker
Carefully note that the penalty is 20 min and the time given is in seconds. |
||||||
2012-02-04 21:30:57 Ajay Gupta
i need more test cases can anyone help me out pls!! |
||||||
2012-02-01 15:23:37 Ayush Verma
use while((scanf(arguments)!=EOF) and its 20 mins not 20 secs...the comments regarding this fact were misleading.... |
||||||
2012-01-31 18:59:39 Secret
got 4 WA bcoz of penality is estimated in seconds :( |