title: Starting a word with Caret and ending with Dollar does not produce expected result
body: <p>I have the following code.</p>
  
  <pre><code>string pattern5 = "^ba$";
  string myString5 = "badabyba";
  bool match5 = Regex.IsMatch(myString5, pattern5);
  Console.WriteLine(match5); // should print True but I see False
  </code></pre>
  
  <p>I want to find a match in a string which starts with <code>ba</code> and ends with <code>ba</code>. If I use both <code>^</code> and <code>$</code> in a single pattern it does not give me expected result. But if I use either <code>^</code> or <code>$</code> (<code>^ba</code> or <code>ba$</code>) then I get expected result, but if <code>myString5</code> is <code>ba</code> then it shows True, which is not what I want.</p>
  
  <p>Is it illegal to use <code>^</code> and <code>$</code> together in this way?</p>