title: How to get the last character of a &str?
body: <p>In Python, this would be <code>final_char = mystring[-1]</code>.  How can I do the same in Rust?</p>
  
  <p>I have tried</p>
  
  <pre><code>mystring[mystring.len() - 1]
  </code></pre>
  
  <p>but I get the error <code>the type 'str' cannot be indexed by 'usize'</code></p>