title: Simulates repeated rolls of a pair of dice until 100 rolls of r have been obtained; the number of rolls is then printed
body: <p>I'm trying to count how many rolls it takes to get 100 rolls of a sum of two dice, r (2-12) and prints it. This is what I've tried so far:</p>
  
  <pre><code>from random import randrange
  def diceprob(r):
      count = 0
  
      while count &lt; 100:
          roll = random.randrange(2, 13)
          if roll == r:
              count += 1
      print("It took {} rolls to get 100 rolls of {}".format(count, r))
  </code></pre>
  
  <p>But when ran, it always prints out, "It took 100 rolls to get 100 rolls of 5", with the value of of 5 changing based on what r is called as. Why isn't the count being incremented properly?</p>