title: Why is the following string comparison code returning TRUE after appending 0x81
body: <p>The following code is a workaround that will allow us to use some functionality from our existing product without changing any code in it. It is a good thing for us but I want to understand why this works? What is special about the 0x81 character?  </p>
  
  <pre><code>"A".Equals(Encoding.UTF8.GetString(new byte[] { 0x41, 0x81 }), StringComparison.InvariantCulture) // Returns TRUE
  </code></pre>
  
  <p>The above code works for CurrentCulture and InvariantCulture but NOT for Ordinal. That makes sense because in ordinal, each byte is compared which would fail in the code above. And it does not work with Default Encoding (SBCS).</p>