C# Trim string regardless of characters
<p>So here the situation.</p>

<p>I have multiple strings that begin and end with a random amount of spaces.  The problem is the string contains multiple words so I can't just replace(" ","") so for example.</p>

<pre><code>"       apple red "
'   orange orange   '  
'  pear grapes  '  
'                   turnship turn it over here '  
</code></pre>

<p>and I would want to return.<br>
    'apple red'<br>
    'orange orange'<br>
    'pear grapes'<br>
    'turnship turn it over here '  </p>
