class FunWithScheduling
{
static void Main()
{
StringBuilder newFile = new StringBuilder();
string temp = "";
string[] file = File.ReadAllLines(Scheduler.txt");
foreach (string line in file)
{
if (line.Contains("Subhadra"))
{
temp = line.Replace("Subhadra", "Thangam");
newFile.Append(temp + "\r\n");
continue;
}
newFile.Append(line + "\r\n");
}
File.WriteAllText("Scheduler.txt", newFile.ToString());
}
}
问问题
69 次