I think it's obvious from the setup of the puzzle that the prisoners lives are completely expendable without repercussion. That kind of precludes any of the more liberal/modern methods of handling prisoners and leans more towards medieval-style prisons.
I don't disagree with you on the obviousness of the set-up. I'm drawing attention to the more subtle language structure which, by design, defines prisoners as non-persons.
I quite like the mathematics of the puzzle, I also like justice and am aware that justice is a product of language in many instances, as many people interact with the world through language without giving much thought to it.
... and as second goal, becoming a prisoner in jail some time later, for the cheap prize of some bottles of wine.
This is the kind of problems that AI machines would try to solve, wrongly. Humans still score better understanding that some theoretical problems must not be solved.