Welsh Piper's imploding dice

## Welsh Piper's imploding dice

Return to topic list

 Fri May 1 00:12:19 2020   by   morethanpixels Help! Would someone use this attempt at pseudocode to make Troll code so we can see the probability distribution? I gave it an honest effort, but saw rather more frustration than progress./ Inspired by ... https://welshpiper.com/imploding-dice// while CR < mark, keep rolling and accumulate total; CR is the current roll/ definitions and first roll; using d10 as an exampleassign d10 to CR, assign CR to mark, assign CR to total/ subsequent rolls, if anyassign d10 to CRIF CR < mark THEN add CR to total assign CR to mark [repeat/recursion to keep going] ELSE [done]I wouldn't be surprised if I'm missing a simple & elegant solution to this. Sat May 2 12:25:15 2020   by   Torben Your problem is probably that the accumulate expression also includes the last roll (that did not fulfil the condition).  But you can filter that out afterwards:`mark := d10;mark + sum (mark > accumulate x:=d10 while x

Return to topic list

New message:
 Topic: Posted by:

Type the values of the dice shown below:

Return to topic list