Skip to content

A cunning plan!

Well, after some persistence I can participate at the Dutch Programming Championship as a spectator (too old to join as contestant :-P ). I’ve worked out an interesting observation during the university-level round held 2 weeks ago.

First some background:

The ICPC model (used during the whole lot from uni-level to country-level to europe-level to world-level) of programming championship involves your team (team size maximum 3, but there’s only one computer) getting 7 to 9 assignments. The assignments vary in difficulty and are randomly ordered. You get 5 hours to solve as many of the assignments as you can. You can submit solutions for an assignment as often as you like, and each attempt (successfull or not) is logged on a publically viewable scoreboard. A correct submission scores you a scorepoint, but also costs you X penalty minutes, where X = (time since start of tournament in minutes + 20* wrong submits). Your performance is rated first on scorepoints (so with 3 points you win from all 2-pointers, regardless of penalty minutes). If the scorepoints are a tie, the penalty minutes become relevant.

In other words, as long as you don’t ever solve a certain assignment, you can submit as many wrong solutions as you like, with no penalty whatsoever. Your attempts show up on the scoreboard, but no clue is given as to why the submit was wrong (not even to you, by the way).

One of the challenges is to finish the assignments in the correct skill order, from easiest to hardest. That way you pick up as few penalty minutes as possible. Some puzzles are obvious in skill level, but some seem so incredibly convoluted that there’s a gimmick or it’s NP-complete and thus simply a matter of working out any solution – it ought to be fast enough. (A big part of the game is to submit a fast entry; the reference implementation’s time is multiplied by about 10ish, and any submissions slower than that are wrong. Most assignments are trivially easy if it WERENT for the requirement that you build the fastest order of algorithm).

Trying to analyse if an assignment is ‘hard’ or ‘easy’ is very difficult. The scoreboard has traditionally provided a big clue. If you notice a load of teams quickly (you can see the time difference between 2 successfull submits by looking at the penalty minutes and attempts, and doing the math) solving an ostensibly difficult assignment, you can bet good money there’s a hidden gimmick that allows you to reduce the whole thing to a trivial set of loops or even a one-liner formula. If no one is trying a certain assignment at all, you can bet fair money everyone who has looked at it so far thinks its hard.

All teams clue off of each other for which assignments to try. However, and here’s the interesting bit: During the university-local rounds (every university runs the same assignment set), universities only see their own university’s team’s scoreboard. Turns out that per university, the set of assignments that no one tried is different. In Delft, no one tried I, at another university, no one tried G. Apparently, if the first couple of groups start trying one assignment, the rest automatically assume those must be the easy ones and also try the same ones. This in turn drives still more groups over to try those ones – yet the actual chances that the one everyone’s working on is the next easiest couple of assignments in line is not at all a certainty.

Wisdom of Crows? Nope, even in this case, where you can barely see what people think, and there’s plenty of good reasons not to blindly follow the crowd, and most participants do have a clue, does wisdom of the crowd fail. I re-assert my theory that any kind of easy viewing of choices made by others before reverses the Wisdom of Crowds and gives you the Stupidity of Sheeple. I bet if you remove the scoreboard completely, the spread of tried assignments roughly matches the difficulties.

And now for my cunning plan:

During the NKP (21st of October of memory serves), I’ll quickly submit an empty solution for those assignments I’m guessing are very difficult. I’m likely correct, in which case I waste no penalty points (you get no penalty points for assignments that you never succeeded at, even if you submitted many wrong ones), and I might convice other teams to waste time on them, especially if I convince one or two other teams on the sly to try the same trick. The scoreboard will then list 2 teams quickly trying assignment X – all wrong, but still trying, which might cause people to veer to that one, under the assumption we figured out a gimmick (especially if we submit faster than ordinary programming appears to suggest is possible, insinuating there’s a trick to quickly calculate the answer) and are just polishing out some bugs.

In the unlikely case I’m wrong and the assignment is actually easy/there IS a gimmick, those same people I inadvertently pointed at the assignment will at some point succeed, and this will be reflected on the scoreboard. Depending on the performance of the succeeding teams and the time it took, I can then make a much more solid assessment of the chance of solving that assignment – without spending more than about 2 minutes analysing it.

It isn’t cheating: the other team(s) that are playing the same psychological game do not have to communicate with each other during the game. Seeing them quickly submit a wrong answer for an assignment that looks, at a quick 1 minute glance, not trivial, tips you off what’s going on, and then you can submit an empty file yourself, shoring up the appearance that there must be a gimmick. In fact, it’s beneficial: That way you can leech off of each other’s assessment.

If I spent 10 minutes verifying that assignment C is indeed nigh undoable, and some other team spends 10 minutes doing the same thing to H, our mutual quick submits tip us off that neither is worth trying until someone nails it and proves us wrong, yet for those who don’t know what we’re doing, it actually looks like C and H are easy.

Of course some tactical planning is neccessary to make it look somewhat believable (submitting an empty C and H 2 minutes apart would be bad, but a 15 to 20 minute hole sounds good).

I’ll let you know how it works out.

NB: Readers who are going, you know what to do :-)