title: Get the specific element in JAVA String[]
body: <p>I wish to get the specific element named <em>Something</em> in a string within a String[] for JAVA.</p>
  
  <p>My code = </p>
  
  <pre><code>String sentence = "AP=Something+example|AS=Explanation";
  String[] word = sentence.split("\\|");
  for (String w: word){
     System.out.println(w);
  }
  </code></pre>
  
  <p>My current output:</p>
  
  <pre><code>AP=Something+example
  AS=Explanation
  </code></pre>
  
  <p>My expected output should be:</p>
  
  <pre><code>Something // the other information I dont want to take. Is there a better and faster way and not too time consuming? 
  </code></pre>
  
  <p>Thank you in advance</p>