El Niño Drawing

Every year after christmas the El Niño Cup takes place. It is a tournament where the result is less important than exercising and having fun. There is a team day, where every team plays Volleyball, Basketball and Unihockey, and a single day, where the disciplines are Badminton, Table Tennis and Archery.

Last year I wrote a program to ease the drawing. It is a fairly complex problem:

  • Every participant must have six matches, two for every discipline, against members of its category (men, women, mixed…)
  • There should be not two matches against the same adversary (except if the category has less than 7 players)
  • Between two matches there should be a break of at least the duration of one match

This year I enhanced the program some more. The amount of tweaking the program output by hand is now almost zero. Just some games remained to be exchanged to satisfy the at-least-one-break condition.

This entry was posted in Games and Sports, Programming. Bookmark the permalink.

Comments are closed.