title: How to calculate completion percentage in the parallel for?
body: <p>With <code>for</code> calculating the completion percentage is easy:</p>
  
  <pre><code>for (int i = 0; i &lt; 10; i++)
  {
      for (int j = 0; j &lt; 10; j++)
      {
          // Do somethings...
          Console.WriteLine("{0}% Done!", i * 10 + j + 1);
      }
  }
  </code></pre>
  
  <p>Output:</p>
  
  <pre><code>1% Done!
  2% Done!
  3% Done!
  4% Done!
  5% Done!
  6% Done!
  7% Done!
  8% Done!
  9% Done!
  10% Done!
  11% Done!
  12% Done!
  13% Done!
  ...
  93% Done!
  94% Done!
  95% Done!
  96% Done!
  97% Done!
  98% Done!
  99% Done!
  100% Done!
  </code></pre>
  
  <hr>
  
  <p>But I don't have any idea about the calculating completion percentage with <code>Parallel.For</code>:</p>
  
  <pre><code>Parallel.For(0, 10, i =&gt;
  {
      Parallel.For(0, 10, j =&gt;
      {
          // Do somethings...
          Console.WriteLine("{0}% Done!", i * 10 + j + 1);
      });
  });
  </code></pre>
  
  <p>Output:</p>
  
  <pre><code>1% Done!
  2% Done!
  3% Done!
  51% Done!
  52% Done!
  53% Done!
  54% Done!
  55% Done!
  56% Done!
  57% Done!
  58% Done!
  59% Done!
  60% Done!
  4% Done!
  5% Done!
  6% Done!
  ...
  69% Done!
  70% Done!
  71% Done!
  72% Done!
  73% Done!
  74% Done!
  75% Done!
  76% Done!
  77% Done!
  78% Done!
  79% Done!
  80% Done!
  36% Done!
  37% Done!
  38% Done!
  39% Done!
  40% Done!
  35% Done!
  </code></pre>
  
  <p>The output is not shown the correct completion percentage.</p>
  
  <p>How to calculate completion percentage in the <code>Parallel.For</code> without reduce the performance?</p>