title: Find Text between special characters and replace string
body: <p>For instance I have a String that contains: </p>
  
  <p><code>String s = "test string *67* **Hi**";</code></p>
  
  <p>I want to to get this String :</p>
  
  <pre><code>*67*
  </code></pre>
  
  <p>With the stars, so I can start replace that part of the string. My code at the moment looks like this:</p>
  
  <pre><code>String s = "test string *67* **Hi**";
  
          s = s.substring(s.indexOf("*") + 1);
          s = s.substring(0, s.indexOf("*"));
  </code></pre>
  
  <p>This outputs: <code>67</code> without the stars.</p>
  
  <p>I would like to know how to get a string between some special character, but not with the characters together, like I want to.</p>
  
  <p>The output should be as followed:</p>
  
  <pre><code>//output: test string hello **hi**
  </code></pre>