automatic "lotjes trekken"

Greg Ewing greg.ewing at compaq.com
Wed Nov 24 05:46:32 EST 1999


Martijn Faassen wrote:
> 
> So,
> each time a person is drawn by someone, the program removes that program
> from everybody else's lists (if that person was in there in the first
> place).

That doesn't guarantee that everyone gets drawn, though.
You might get down to drawing for the last person and find
that there's nobody left on their list, even though there
are people remaining on other lists that have never been
drawn.

I can't think of any method that wouldn't have to backtrack
under some circumstances.

But is that really a problem in practice? How big a data
set are we talking about? Unless you have a REALLY BIG
family with lots and lots of conflicts, I'd expect a
solution to be found fairly quickly in most cases, even
if theoretically it could take a long time for some
pathological cases.

Greg




More information about the Python-list mailing list