Did you know ... Search Documentation:
Predicate dist/3
 dist(+Dist:list(pair(prob,A)), -X:A) is nondet
 dist(+Ps:list(prob), +Xs:list(A), -X:A) is nondet
Probabilistic choice from given distribtion, which can be supplied as a list of pairs (dist/2) or two lists (dist/3).