When your question is answered use !solved to mark the question as resolved.
Remember to ask specific questions, provide necessary details, and reduce your question to its simplest form. For tips on how to ask a good question use !howto ask.
10 messages Β· Page 1 of 1 (latest)
When your question is answered use !solved to mark the question as resolved.
Remember to ask specific questions, provide necessary details, and reduce your question to its simplest form. For tips on how to ask a good question use !howto ask.
INPUT FORMAT (input arrives from the terminal / stdin):
The first line contains N
.
The second line contains N
integers a1β¦aN
, the initial bacteria levels of each patch of grass.
OUTPUT FORMAT (print output to the terminal / stdout):
The minimum number of applications necessary to make every patch of grass have the recommended value of bacteria for healthy grass.
SAMPLE INPUT:
2
-1 3
SAMPLE OUTPUT:
6
Use the type of pesticide that removes bacteria, at a power level of 1, five times. Then use the type of pesticide that adds bacteria, with a power level of 2
, one time.
SAMPLE INPUT:
5
1 3 -2 -7 5
SAMPLE OUTPUT:
26
time limit is 2 secs
Bro is this the usaco this weekend πππ
yeah I did it yesterday
wdym