title: Pythonic way to select list elements with different probability
body: <pre><code>import random
  pos = ["A", "B", "C"]
  x = random.choice["A", "B", "C"]
  </code></pre>
  
  <p>This code gives me either "A", "B" or "C" with equal probability.
  Is there a nice way to express it when you want "A" with 30%, "B" with 40% and "C" with 30% probability?</p>