#P1915. [NOI2010] 成长快乐
[NOI2010] 成长快乐
Output Format
For the given input files nemo1.in nemo10.in, you need to submit the corresponding output files nemo1.out nemo10.out.
The first line of the output file contains an integer , indicating that in your growth plan, Nemo will eat shrimps.
The second line contains a real number , indicating the total weight of shrimps that Nemo eats in your plan.
The next lines each contain numbers . This means that at time , Nemo eats shrimp numbered at position . Here are real numbers, and is an integer.
To ensure the precision of the checker, it is recommended to output all real numbers with at least digits after the decimal point. In the checker, two real numbers are considered equal if their absolute difference does not exceed .
5 1 6 0 0
1
5 2 2 0 0
1
5
5 2 2 1
Hint
Sample explanation
In this sample, Nemo eats shrimp at position at time . In fact, Nemo could reach earlier, but the problem only requires that the speed not exceed .
Scoring
For each dataset, we set scoring thresholds . If your output is invalid, you get zero points. Otherwise, let the increase in Nemo’s weight in your plan be . Your score is determined by the following table:
| Score | Condition | Score | Condition |
|---|---|---|---|
| 10 | 5 | ||
| 9 | 4 | ||
| 8 | 3 | ||
| 7 | 2 | ||
| 6 | 1 |
How to use the checker
In the checker directory, run ./checker in out in the terminal.
Here, in is the input file provided by the problem, and out is your answer file for that input.
The checker only verifies the validity of your output. Final results are subject to the online judge.
Thanks to @FlierKing for providing the SPJ and to @虞皓翔 for helping improve the SPJ.
Translated by ChatGPT 5
京公网安备 11011102002149号