title: Split string and set default value if separator not found WITH LINQ
body: <p>I have a similar question than this post: <a href="https://stackoverflow.com/questions/3723499/c-sharp-string-splitting">C# string splitting</a> but it's bit old and use Regex as solution.</p>
  
  <p>So here's my input (array of string)</p>
  
  <pre><code>foo.xml
  bar.png
  pdf
  </code></pre>
  
  <p>What I want is to retrieve the files extensions without dot and set "unknown" when no dot is found.</p>
  
  <pre><code>xml
  png
  unknown
  </code></pre>
  
  <p>What I tried that didn't work</p>
  
  <pre><code>_filesName.Select(a =&gt; a.Split('.').Select(b =&gt; string.IsNullOrEmpty(b) ? "unknown":b).Last());
  </code></pre>
  
  <p>return </p>
  
  <pre><code>xml
  png
  pdf // WRONG!! Why its not set to unknown?
  </code></pre>
  
  <p>Is it possible to do what I want using LINQ?</p>