A Notice To All Those Doing Senior:
So far every submission to the senior problem has underestimated the complexity of the problem and scored maybe 40/100 points.
I'm not going to explain why. But here's a simple test case that exploits the major flaw in all submitted algorithms.
Sample Input #2:
Sample Output #2:
Explanation Of Sample Data #2:
Jump the first hurdle for 500 joules to avoid a 9 second penalty. Knock the second hurdle over for a 2 second penalty.
This mistake is not so simple to fix either. You may have to rethink your approach to the problem. Notice the upper bound on the input (n <= 100). There's a good reason it's so small, but still not small enough for an
)
brute force approach.
Good luck!