Remove Extra back slash "\" from string file path in c#
<p>How to convert </p>

<p><code>"String path = @"C:\Abc\Omg\Why\Me\\\\\\\\\\\\\\\\\\\\\";</code> </p>

<p>into</p>

<p><code>String path = @"C:\Abc\Omg\Why\Me\"</code>. </p>

<p>My approach is to first <code>reverse</code> the <code>string</code> and then <strong>remove all</strong> the <code>"\"</code> till we get <strong>first</strong> <code>char</code>, and the <code>reverse</code> it again.</p>

<p>How to do this in C#, is there any method for such operation?</p>