This is a computer version of the statistical game "Glupska Grisen". It's also an experiment in which I've been trying to determine the ultimate way of playing the game.
Turned out (after I simulated 500000 games of each strategy), that the answer is to sit down as soon as the total has surpassed 21. That gives an average of 97.77554 points per round.