title: Difference between UTF-8 and UTF-16?
body: <p>Difference between UTF-8 and UTF-16?
  Why do we need these?</p>
  
  <pre><code>MessageDigest md = MessageDigest.getInstance("SHA-256");
  String text = "This is some text";
  
  md.update(text.getBytes("UTF-8")); // Change this to "UTF-16" if needed
  byte[] digest = md.digest();
  </code></pre>