using System.Text.RegularExpressions;
public static void Main()
Every night in my dreams I see you, I feel you
That's how I know you go on
Far across the distance and places between us
You have come to know you go on
bool preserveTabs = false;
text = Regex.Replace(text, @" +", " ");
text = Regex.Replace(text, @" *\t *", "\t");
text = Regex.Replace(text, @"[ \t]+", " ");
text = Regex.Replace(text, @"([\t ]*(\n)+[\t ]*)+", "\n");
Console.Write("\nClean New Lines\n======\n" + text);