title: Does Lists in C# support slicing like in Python?
body: <p>Sorry for such a basic question regarding lists, but do we have this feature in C#?</p>
  
  <p>e.g. imagine this Python List:</p>
  
  <pre><code>a = ['a','b,'c']
  print a[0:1]
  
  &gt;&gt;&gt;&gt;['a','b']
  </code></pre>
  
  <p>Is there something like this in C#? I currently have the necessity to test some object properties in pairs. edit: pairs are always of two :P</p>
  
  <p>Imagine a larger (python) list:</p>
  
  <pre><code>a = ['a','a','b','c','d','d']
  </code></pre>
  
  <p>I need to test for example <code>if a[0] = a[1]</code>, and <code>if a[1] = a[2]</code> etc.</p>
  
  <p>How this can be done in C#?</p>
  
  <p>Oh, and a last question: what is the tag (here) i can use to mark some parts of my post as code?</p>