title: How do I write a While loop
body: <p>How do you write the syntax for a While loop?</p>
  
  <h2>C<code>#</code></h2>
  
  <pre><code>int i = 0; 
  while (i != 10)
  { 
     Console.WriteLine(i); 
     i++; 
  }
  </code></pre>
  
  <h2>VB.Net</h2>
  
  <pre><code>Dim i As Integer = 0
  While i &lt;&gt; 10
      Console.WriteLine(i)
      i += 1
  End While  
  </code></pre>
  
  <h2>PHP</h2>
  
  <pre><code>&lt;?php
  while(CONDITION)
  {
  //Do something here.
  }
  ?&gt;
  
  
  &lt;?php
  //MySQL query stuff here
  $result = mysql_query($sql, $link) or die("Opps");
  while($row = mysql_fetch_assoc($result))
  {
  $_SESSION['fName'] = $row['fName'];
  $_SESSION['lName'] = $row['lName'];
  //...
  }
  ?&gt;
  </code></pre>
  
  <h2>Python</h2>
  
  <pre><code>i = 0
  while i != 10:
      print i
      i += 1
  </code></pre>