title: Finding PI digits using Monte Carlo
body: <p>I have tried many algorithms for finding π using Monte Carlo.
  One of the solutions (in Python) is this:</p>
  
  <pre><code>def calc_PI():
      n_points = 1000000
      hits = 0
  
      for i in range(1, n_points):
          x, y = uniform(0.0, 1.0), uniform(0.0, 1.0)
  
          if (x**2 + y**2) &lt;= 1.0:
              hits += 1
  
      print "Calc2: PI result", 4.0 * float(hits) / n_points
  </code></pre>
  
  <p>The sad part is that even with 1000000000 the precision is VERY bad (<strong>3.141...</strong>).</p>
  
  <p>Is this the maximum precision this method can offer?
  The reason I choose Monte Carlo was that it's very easy to break it in parallel parts.
  Is there another algorithm for π that is easy to break into pieces and calculate?</p>