title: C#: Nested conditionals vs continue statement
body: <p>In using ReSharper recently, it is suggesting I reduce nesting in certain places by inverting <code>if</code> conditions and using the <code>continue</code> statements.</p>
  
  <p><strong>nested conditionals:</strong></p>
  
  <pre><code>foreach(....)
  {
      if(SomeCondition)
      {
          //do some things
  
          if(SomeOtherNestedCondition)
          {
              //do some further things
          }
      }
  }
  </code></pre>
  
  <p><strong>continue statements:</strong></p>
  
  <pre><code>foreach(....)
  {
      if(!SomeCondition) continue;
  
      //do some things
  
      if(!SomeOtherNestedCondition) continue;
  
      //do some further things
  }
  </code></pre>
  
  <p>I understand some of the logic of why you'd want to reduce nesting for performance and memory issues as well as how the two snippets equate to each other, however from my development background, the <em>before</em> example is easier to follow when reading the code. </p>
  
  <p>Which approach do you prefer and why? Do you use <code>continue</code> over nested ifs in your everyday code?</p>