I haven’t attended the contest, but, I’ve read the editorial for TCP problem and it seems to involve numerical methods for integration/function approximation(and/or generation) by polynomial curves so that numerical methods can be employed.
In general, it’s quite hard to perform interpolations correctly, and, even if we are given the sufficient number of points (if we have a polynomial of degree N, we need N+1 points.), slight changes in the function coefficients might affect the overall area estimation (this is known I believe to be something along the lines of numerical stability or something alike).
So, possibly outputting negative values is enough for the judge due to precision being very close to 0 (10^(-10) is very, very small.).
The only problem I had seen before which slightly involved numerical methods was this one. But, in the end, it turned out a simple greedy method worked…
So, to wrap this up, it seems that while the problem was awesome in its own right and it presented a great application of numerical methods to competition programming/real life scenarios, it’s also hard to ensure correction of test data on such problems, but, nontheless, I got quite inspired by this problem to maybe write something similar in a future contest