title: Regex to get the file extension
body: <p>I have a list which contains file names (without their full path)</p>
  
  <pre><code>List&lt;string&gt; list=new List&lt;string&gt;();
  
  list.Add("File1.doc");
  list.Add("File2.pdf");
  list.Add("File3.xls");
  
  foreach(var item in list) {
      var val=item.Split('.');
      var ext=val[1];
  }
  </code></pre>
  
  <p>I don't want to use <code>String.Split</code>, how will I get the extension of the file with regex? </p>