This week, 5.3.2009, X-tra easy competition will take place. There will be a total of 5 tasks (2 really easy, 2 easy, and one medium). Because a big tie is expected, time limits are set relatively tight (my solution + 0.2s), so in case time (2 hours) remains to you, I suggest going through code again and making possible optimistaions (so at least replacing cin/cout with scanf/printf).
So, apart from coding fast you have to optimise your code all you can? I don't like the second thing if the algorithm needs a lot of "tiny" optimizations, because I think that's not the point in a programming contest.
No, no tiny optimisations, just major ones (using scanf when 2mb input). As I said, my solution +0,2s. That's not too bad. I hope there won't be too big tie, but we'll see.
I sortof notified admin, so it seems he's okay with it... And I also don't think there'll be any problem, as algorithm is almost obvious when you see the task.
I ask because if it is ACM-like the submition time is an important factor, and as this competition seems to be about how fast, and good!, you can solve a problem set, it can be an ACM-like competition.
You guessed right. The competition is IOI like. So this means only one test case is evaluated at competition time, the remaining ones are evaluated afterwards. Correct me if I'm wrong.
Mine too, I used the cosinus theorem and then Pithagora's theorem and I'm positive that I've done it correct, also I can't believe that I get all TLE at Magic - Four, I have just one function call, standard function in Pascal.
The best way for Magic problem is to store the index of all 4 consecutive char of the long string in an array, then loop on the given short strings and print.
@Tavo: The periodic table is a big mistery to me also... Don't know what happened. But when I test it under "My tasks", i get 100/100. @Aleksandar: Magic four requires hashing if you want to get points. @RobertGerbicz: I have already said it 4 times, there shouldn't be such cases. @oa12gb and others: You had to use PI up to 10 decimals, and DOUBLE, not FLOAT!
I really don't know what's happening with testing those endlines! They sould be ignored anyway!
@s-lime: Unfortunately the discussions during the event are lost (i guess), but there, when you provided with the 1st test case, there WAS a 'CAS' situation (it was not a seperate word but in the middle of another, though the CaS - CAs situation remains). You have the tests, just take a look.
So, let's get to answer one by one: @N.vilcinis: Consider the "acas", despite it contains "cas", there is only one solution AcAs. You just have to think. I said there won't be such cases. That a substring contains CAS, it simply doens't matter. @Daniel93: 42.54110 143.19143 @PI: Yes, I used it 10 decimals or so... But it simply doesn't matter, because the difference is too small, that it wont pass through .5, making the rounding up instead of down. It was more important to use double (16 digit precidion) instead of float (6 digit precision.)
@Daniel93, i used 16 decimals as double holds 16 places... #define PI 3.1415926535897932 and I get AC... Sorry, but that's not my fault. The task is asking for 5 accurate decimals (rounded), and you had to calculate so, taking pi as whatever is enough.
Tasks will be available for solving when they are confirmed OK, and I have already said that (now when periodic table have been fixed), so the answer is as soon as admin sees this.