The ^ character is used to match the beginning of a string, code example
string s = "I am a blue cat.";
string res= Regex.Replace(s, "^", "开始");
Console.WriteLine(res);
Console.ReadKey();
The output is
The $ positioning metacharacter is used to match the end of a string, code example
string s = "I am a blue cat.";
string res= Regex.Replace(s, "$", "结束");
Console.WriteLine(res);
Console.ReadKey();
The output is