I want to replace all occurences of multiple slash ('') with single backslash
For example
mama\\\\Please\\\\\U0U0001f973\U00.txt
Result should be this
mama\Please\U0U0001f973\U00.txt
I have tried
string file = "mama\\\\Please\\\\\U0U0001f973\U00.txt"
string output = Regex.Replace(file, @"[/\\]{2,}", @"\");
current result
mama\\Please\\\U0U0001f973\U00.txt