title: Java: Using String.indexOf() to check for the apostrophe character
body: <p>I am trying to parse a string and I need to use substring to do it. The string contains the apostrophe characters. My question is, how do I use temp to get String.indexOf to get the index of the apostrophe character?</p>
  
  <pre><code>//temp variable currently contains the string 'hello' including the apostrophe character
  String finalWord = temp.substring(temp.indexOf('''), temp.indexOf('.')); 
  </code></pre>