Is there a mechanism to automatically reorder code statements based on a variable?
<p>the title doesn't explain my question at all<br>
my question regards the fact that if you have a variable X and Y and you apply this code <br> to them:</p>

<pre><code>int x = 10;
int y = 0;
x++;
y = x;
out(y);
</code></pre>

<p>than the order of the code is critical to the output.<br></p>

<p><strong>so my question</strong>: is there a key word that has the computer run the code at a certain order <br> depending on a variable</p>

<p><strong>selOrder</strong> is a key word that <strong>I just made up</strong> for the sake of this example <br> it gets a Boolean value and with it determines which line to execute first  <br/></p>

<pre><code>example:
{
      int x = 10;
      int y = 0;
      bool order = true;
      selOrder(order)
      {
          x++;
      }
      {
          y = x;
      }
      out(y);
}
</code></pre>

<p>out : 11</p>

<p>this example is quite ridiculous and it makes this question look pathetic<br>but I am all serious and although in this example this key word is useless<br>I have stumbled across many codes were it could be quit nifty</p>

<p>thanks in advanc</p>
