title: How to change progress bar in loop?
body: <p>I have html code. And i need some javascript code for update value on every iteration</p>
  
  <pre><code>&lt;progress id="progressBar" max="100" value="0"&gt;&lt;/progress&gt;
  
  
  for (i = 0; i &lt;= 100; i ++) {
      //update progress bar
  }
  </code></pre>
  
  <p>I try to do something like this:</p>
  
  <pre><code>var progressBar = document.getElementById("progressBar");
  progressBar.value += i;
  </code></pre>
  
  <p>But this not work. It update progress bar when loop finish.</p>